diff --git a/.circleci/config.yml b/.circleci/config.yml index f306634337..c8fa7cd150 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -331,13 +331,19 @@ jobs: steps: - checkout - run: - name: Install Node.js - # First we remove system node and npm to ensure they're not used in later 'run' steps + name: Update Node.js command: | - rm -rf $(which node) - rm -rf $(which npm) - curl -sL https://deb.nodesource.com/setup_10.x | sudo -E bash - - sudo apt-get -y install nodejs + # NVM is already installed, we just need to load it... + [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" + # ...export for subsequent runs... + echo 'export NVM_DIR="/opt/circleci/.nvm"' >> $BASH_ENV + echo "[ -s \"$NVM_DIR/nvm.sh\" ] && . \"$NVM_DIR/nvm.sh\"" >> $BASH_ENV + nvm install 10 + nvm alias default 10 + nvm use default + # ...and finally symlink for when calling Garden with sudo below + sudo ln -s "$NVM_DIR/versions/node/$(nvm version)/bin/node" "/usr/local/bin/node" + sudo ln -s "$NVM_DIR/versions/node/$(nvm version)/bin/npm" "/usr/local/bin/npm" - npm_install - run: npm run build - run: @@ -420,6 +426,8 @@ workflows: requires: - build-dist-edge - test-dist + - test-minikube: + <<: *only-master tags: jobs: @@ -453,4 +461,6 @@ workflows: <<: *only-tags requires: - build-dist - - test-dist \ No newline at end of file + - test-dist + - test-minikube: + <<: *only-tags