diff --git a/.circleci/config.yml b/.circleci/config.yml index eab76c4a6..9a65e928a 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -117,9 +117,11 @@ jobs: - run: name: Decrypt credentials. command: | - openssl aes-256-cbc -d -in .circleci/key.json.enc \ + if ! [[ -z "${SYSTEM_TESTS_ENCRYPTION_KEY}" ]]; then + openssl aes-256-cbc -d -in .circleci/key.json.enc \ -out .circleci/key.json \ -k "${SYSTEM_TESTS_ENCRYPTION_KEY}" + fi - run: *npm_install_and_link - run: *samples_npm_install_and_link - run: @@ -131,7 +133,10 @@ jobs: NPM_CONFIG_PREFIX: /home/node/.npm-global - run: name: Remove unencrypted key. - command: rm .circleci/key.json + command: | + if ! [[ -z "${SYSTEM_TESTS_ENCRYPTION_KEY}" ]]; then + rm .circleci/key.json + fi when: always working_directory: /home/node/samples/ system_tests: @@ -143,9 +148,11 @@ jobs: - run: name: Decrypt credentials. command: | - openssl aes-256-cbc -d -in .circleci/key.json.enc \ + if ! [[ -z "${SYSTEM_TESTS_ENCRYPTION_KEY}" ]]; then + openssl aes-256-cbc -d -in .circleci/key.json.enc \ -out .circleci/key.json \ -k "${SYSTEM_TESTS_ENCRYPTION_KEY}" + fi - run: *npm_install_and_link - run: name: Run system tests. @@ -154,7 +161,10 @@ jobs: GOOGLE_APPLICATION_CREDENTIALS: .circleci/key.json - run: name: Remove unencrypted key. - command: rm .circleci/key.json + command: | + if ! [[ -z "${SYSTEM_TESTS_ENCRYPTION_KEY}" ]]; then + rm .circleci/key.json + fi when: always publish_npm: docker: @@ -162,6 +172,6 @@ jobs: user: node steps: - checkout - - npm install + - run: npm install - run: echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" > ~/.npmrc - run: npm publish --access=public diff --git a/.kokoro/docs.sh b/.kokoro/docs.sh old mode 100644 new mode 100755 diff --git a/.kokoro/lint.sh b/.kokoro/lint.sh old mode 100644 new mode 100755 diff --git a/.kokoro/samples-test.sh b/.kokoro/samples-test.sh old mode 100644 new mode 100755 diff --git a/.kokoro/system-test.sh b/.kokoro/system-test.sh old mode 100644 new mode 100755 diff --git a/.kokoro/test.sh b/.kokoro/test.sh old mode 100644 new mode 100755 diff --git a/.kokoro/trampoline.sh b/.kokoro/trampoline.sh old mode 100644 new mode 100755