diff --git a/.circleci/dynamic_config.yml b/.circleci/dynamic_config.yml index 836d01ea0e..83a0ddc916 100644 --- a/.circleci/dynamic_config.yml +++ b/.circleci/dynamic_config.yml @@ -317,17 +317,9 @@ jobs: steps: - custom_attach_workspace - install_python - - run: - name: Decrypt Credentials - # Note: when changing the image, you might have to re-encrypt the credentials with a - # matching version of openssl. - # See https://stackoverflow.com/a/43847627/2116927 for more info. - command: | - openssl aes-256-cbc -d -in .circleci/github_token -k "${KEY}" -out ~/github_token -md md5 - run: name: Deployment to Snapshot - command: | - yarn admin snapshots --verbose --githubTokenFile=${HOME}/github_token + command: yarn admin snapshots --verbose - fail_fast publish_artifacts: diff --git a/.circleci/github_token b/.circleci/github_token deleted file mode 100644 index 450cb2c93f..0000000000 --- a/.circleci/github_token +++ /dev/null @@ -1 +0,0 @@ -Salted__z"BY|ۍVQֳUzW/GR e}j% <% \ No newline at end of file diff --git a/scripts/snapshots.ts b/scripts/snapshots.ts index 37a97f3b42..46b0f204c6 100644 --- a/scripts/snapshots.ts +++ b/scripts/snapshots.ts @@ -130,7 +130,6 @@ async function _publishSnapshot( export interface SnapshotsOptions { force?: boolean; - githubTokenFile?: string; githubToken?: string; branch?: string; } @@ -151,11 +150,7 @@ export default async function (opts: SnapshotsOptions, logger: logging.Logger) { branch = '' + process.env['CIRCLE_BRANCH']; } - const githubToken = ( - opts.githubToken || - (opts.githubTokenFile && fs.readFileSync(opts.githubTokenFile, 'utf-8')) || - '' - ).trim(); + const githubToken = (opts.githubToken || process.env.SNAPSHOT_BUILDS_GITHUB_TOKEN || '').trim(); if (githubToken) { logger.info('Setting up global git name.');