Skip to content
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

Fix node version #164

Merged
merged 1 commit into from Jun 19, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
8 changes: 7 additions & 1 deletion .kokoro/e2e-tests/build.sh
Expand Up @@ -14,10 +14,17 @@
# See the License for the specific language governing permissions and
# limitations under the License.

# Fail on error
set -e;

# Remove old logs/YAML files
rm -rf */*.log
rm -rf *-*.yaml

# Load the Node version manager
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm

# Install the latest version of Node 8
nvm install 8

Expand Down Expand Up @@ -45,7 +52,6 @@ function cleanup {
gsutil cp ${BADGE_URL}/${DATA_BACKEND}-${STATUS}.svg ${BADGE_URL}/${GAE_VERSION}.svg
}
trap cleanup EXIT
set -e;

# Configure gcloud
export GCLOUD_PROJECT=nodejs-getting-started-tests
Expand Down
8 changes: 8 additions & 0 deletions .kokoro/e2e-tests/container/build.sh
Expand Up @@ -67,6 +67,14 @@ export MYSQL_PASSWORD=$(cat ${KOKORO_GFILE_DIR}/secrets-mysql-password.json)
export MONGO_URL=$(cat ${KOKORO_GFILE_DIR}/secrets-mongo-url.json)
export INSTANCE_CONNECTION_NAME="${GCLOUD_PROJECT}:us-central1:integration-test-instance"


# Load the Node version manager
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm

# Use Node 8
nvm install 8

# Install Node dependencies
yarn global add @google-cloud/nodejs-repo-tools
cd github/nodejs-getting-started/${BOOKSHELF_DIRECTORY}
Expand Down
13 changes: 10 additions & 3 deletions .kokoro/system-tests/cloudsql.sh
Expand Up @@ -18,6 +18,9 @@
# - Each system test uses a different script for system tests. This is due to the need for database/proxy commands
# - The end-to-end (E2E) tests don't need additional commands (GAE handles that), so they use a common test script

# Fail on error
set -e;

# Remove old logs/YAML files
rm -rf */*.log
rm -rf *-*.yaml
Expand All @@ -31,6 +34,13 @@ export GOOGLE_APPLICATION_CREDENTIALS=${KOKORO_GFILE_DIR}/secrets-key.json
gcloud auth activate-service-account --key-file "$GOOGLE_APPLICATION_CREDENTIALS"
gcloud config set project $GCLOUD_PROJECT

# Load the Node version manager
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm

# Use Node 8
nvm install 8

# Install Node dependencies
yarn global add @google-cloud/nodejs-repo-tools
cd github/nodejs-getting-started
Expand All @@ -42,9 +52,6 @@ find . -name package.json -maxdepth 2 -execdir sh -c "cp $GOOGLE_APPLICATION_CRE
# Start SQL proxy
cloud_sql_proxy -instances="${GCLOUD_PROJECT}:us-central1:integration-test-instance"=tcp:3306 &

# Fail on error
set -e;

# Install dependencies (for running the tests, not the apps themselves)
yarn install

Expand Down
13 changes: 10 additions & 3 deletions .kokoro/system-tests/datastore.sh
Expand Up @@ -18,6 +18,9 @@
# - Each system test uses a different script for system tests. This is due to the need for database/proxy commands
# - The end-to-end (E2E) tests don't need additional commands (GAE handles that), so they use a common test script

# Fail on error
set -e;

# Remove old logs/YAML files
rm -rf */*.log
rm -rf *-*.yaml
Expand All @@ -31,6 +34,13 @@ export GOOGLE_APPLICATION_CREDENTIALS=${KOKORO_GFILE_DIR}/secrets-key.json
gcloud auth activate-service-account --key-file "$GOOGLE_APPLICATION_CREDENTIALS"
gcloud config set project $GCLOUD_PROJECT

# Load the Node version manager
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm

# Use Node 8
nvm install 8

# Install Node dependencies
yarn global add @google-cloud/nodejs-repo-tools
cd github/nodejs-getting-started
Expand All @@ -39,9 +49,6 @@ cd github/nodejs-getting-started
find . -name package.json -maxdepth 2 -execdir sh -c "cp ${KOKORO_GFILE_DIR}/secrets-config.json config.json" \;
find . -name package.json -maxdepth 2 -execdir sh -c "cp $GOOGLE_APPLICATION_CREDENTIALS key.json" \;

# Fail on error
set -e;

# Install dependencies (for running the tests, not the apps themselves)
yarn install

Expand Down