-
Notifications
You must be signed in to change notification settings - Fork 13
Updated circleci config to push to gar #573
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
This reverts commit 48ebec2.
julienw
left a comment
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.
If using the gcp-gcr orb, we should use gcr-auth and push-image from that orb directly.
The gcp-cli is probably not needed!
| echo 'export GOOGLE_PROJECT_ID="moz-fx-profiler-prod"' >> "$BASH_ENV" | ||
| echo "export OIDC_WIP_ID=$GCPV2_WORKLOAD_IDENTITY_POOL_ID" >> "$BASH_ENV" | ||
| echo "export OIDC_WIP_PROVIDER_ID=$GCPV2_CIRCLECI_WORKLOAD_IDENTITY_PROVIDER" >> "$BASH_ENV" | ||
| echo "export GOOGLE_PROJECT_NUMBER=$GCPV2_WORKLOAD_IDENTITY_POOL_PROJECT_NUMBER" >> "$BASH_ENV" | ||
| echo "export OIDC_SERVICE_ACCOUNT_EMAIL=$GCP_SERVICE_ACCOUNT_EMAIL" >> "$BASH_ENV" | ||
| echo 'export GCP_GAR_REPO="profiler-prod"' >> "$BASH_ENV" | ||
| echo "export GAR_IMAGE=\"<<parameters.registry-url>>/${GOOGLE_PROJECT_ID}/${GCP_GAR_REPO}/<<parameters.image>>\"" >> $BASH_ENV |
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.
For more simplicity, and if they are needed, I would create these env variables directly in the step below, like we do for IMAGE_VERSION_TAG IMAGE_LATEST_TAG.
For the hardcoded ones, it could be easier to add an environment property to the job or step like described in parts 2 and 3 in https://circleci.com/docs/set-environment-variable/.
Using the commands with $BASH_ENV are useful if:
- we want some interpolation
- we want these variables present for all the following steps
But I'm not opposed keeping them here if you prefer, buy only if we need them.
No description provided.