
# Conflicts: # .circleci/config.yml # .github/ISSUE_TEMPLATE/1-bug-report.md # .github/ISSUE_TEMPLATE/2-feature-request.md # .github/ISSUE_TEMPLATE/5-support-request.md # .github/ISSUE_TEMPLATE/6-angular-cli.md # .github/ISSUE_TEMPLATE/7-angular-components.md # .ng-dev/commit-message.ts # CODE_OF_CONDUCT.md # CONTRIBUTING.md # README.md # aio/README.md # aio/content/guide/architecture-modules.md # aio/content/guide/architecture-next-steps.md # aio/content/guide/architecture-services.md # aio/content/guide/architecture.md # aio/content/guide/attribute-binding.md # aio/content/guide/bootstrapping.md # aio/content/guide/glossary.md # aio/content/guide/ngmodules.md # aio/content/guide/template-statements.md # aio/content/marketing/analytics.md # aio/content/marketing/docs.md # aio/content/marketing/events.html # aio/content/navigation.json # aio/content/tutorial/toh-pt4.md # aio/content/tutorial/toh-pt6.md # aio/package.json # aio/src/app/shared/ga.service.spec.ts # aio/src/app/shared/ga.service.ts # aio/src/app/shared/location.service.spec.ts # aio/tests/e2e/src/onerror.e2e-spec.ts # aio/yarn.lock
Encryption
Based on https://github.com/circleci/encrypted-files
In the CircleCI web UI, we have a secret variable called KEY
https://circleci.com/gh/angular/angular/edit#env-vars
which is only exposed to non-fork builds
(see "Pass secrets to builds from forked pull requests" under
https://circleci.com/gh/angular/angular/edit#advanced-settings)
We use this as a symmetric AES encryption key to encrypt tokens like a GitHub token that enables publishing snapshots.
To create the github_token file, we take this approach:
- Find the angular-builds:token in the internal pw database
- Go inside the CircleCI default docker image so you use the same version of openssl as we will at runtime:
docker run --rm -it circleci/node:10.12
- echo "https://[token]:@github.com" > credentials
- openssl aes-256-cbc -e -in credentials -out .circleci/github_token -k $KEY
- If needed, base64-encode the result so you can copy-paste it out of docker:
base64 github_token