We are using the awesome Gitlab CI/CD workflow and had been satisfied with the process. A lot of Merge Requests could happen everyday and we want to make sure that our application is update on realtime whenever our pipeline jobs sucessful.
For instance our master branch could also be deployed on staging whenever Merge Request is accepted. Here is our example deploy_staging
job on gitlab-ci.yml
.
deploy_staging:
type: deploy
script:
- yarn install
- node_modules/ember-cli/bin/ember deploy staging --activate
environment:
name: staging
only:
- master
Since ember is a Single Page Application and once new deployment is shipped and available, ember couldn't recognized the new changes. Hence we need to refresh the page to be updated.
The other downside to this idea is, we can't afford to refresh the page if end user is in the middle of transaction. So my thought is to make a notification to refresh the page similar to any mobile app when updates is available they just go to the link and click the update manually.
Now this problem is narrowed down to this:
How can we sent signal to the running ember application so we can prompt a notification to refresh the page whenever updates is available (after successful CI/CD delivery)?
Aucun commentaire:
Enregistrer un commentaire