-
Notifications
You must be signed in to change notification settings - Fork 27.4k
chore(ci): really fix code/docs deployment #17066
Conversation
Previously, the `DIST_TAG` environment variable was failing to be computed correctly, because it was using the non-existent `jq` tool. In the past (when running on TravisCI), `jq` used to be available, but it is not on the currently used CircleCI docker image, resulting in the following error: ```sh ./.circleci/env.sh: line 59: jq: command not found DIST_TAG= ``` You can see an example failure in the "Set up environment" step logs in https://app.circleci.com/pipelines/github/angular/angular.js/ 166/workflows/34c692ec-18d4-4422-a1cf-108a91219fa5/jobs/1742 This commit fixes it by using `node` (which _is_ available on the docker image) to compute `$DIST_TAG`.
Previously, the command used to deploy the docs to Firebase (as part of the `deploy-docs` CI job) would fail, because no target project was specified (either directly in the command or indirectly via a `.firebaserc` file in the working directory). Example failure: https://app.circleci.com/pipelines/github/angular/angular.js/ 166/workflows/34c692ec-18d4-4422-a1cf-108a91219fa5/jobs/1744 This commit fixes the command by specifying the project via the `--project` cli argument. It also adds the commit SHA as message to make it easier to associate a deployment with the corresponding commit.
.circleci/env.sh
Outdated
|
||
#################################################################################################### | ||
#################################################################################################### | ||
## Source `$BASH_ENV` to make the variables available immediately. ## | ||
## ***NOTE: This must remain the the last action in this script*** ## | ||
## ***NOTE: This must remain the last action in this script.*** ## |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This doesn’t sound intended.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why not? 😕
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It’s not aligned with the line above anymore.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is center-aligned(-ish) 😁
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There you go: 986fd8c 😃
Previously, the command used to deploy the docs to Firebase (as part of the `deploy-docs` CI job) would fail, because no target project was specified (either directly in the command or indirectly via a `.firebaserc` file in the working directory). Example failure: https://app.circleci.com/pipelines/github/angular/angular.js/ 166/workflows/34c692ec-18d4-4422-a1cf-108a91219fa5/jobs/1744 This commit fixes the command by specifying the project via the `--project` cli argument. It also adds the commit SHA as message to make it easier to associate a deployment with the corresponding commit. Closes #17066
This PR fixes two issues related to code/docs deployment:
DIST_TAG
environment variable (which is needed in thedeploy-code
CI job).deploy-docs
CI job).See individual commits for details.