From 935444b07a4a54e5f98ecdc7a4672ddae6c92699 Mon Sep 17 00:00:00 2001 From: Sietse Ringers Date: Sat, 7 Mar 2020 13:52:02 +0100 Subject: [PATCH] chore: update .gitlab-ci.yml to use golang_sql docker image --- .gitlab-ci.yml | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 14ecc2a..9c24b0a 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,9 +1,9 @@ -image: privacybydesign/golang_dep:latest +image: privacybydesign/golang_sql:latest -cache: - key: $CI_COMMIT_REF_SLUG - paths: - - vendor/ +#cache: +# key: $CI_COMMIT_REF_SLUG +# paths: +# - vendor/ stages: - test @@ -15,10 +15,13 @@ variables: before_script: - set -euxo pipefail + - service mysql start + - mysql -e "create database test" + - mysql -e "grant all privileges on *.* to 'testuser'@'localhost' identified by 'testpassword'" + - mysql -e "flush privileges" - mkdir -p "$GOPATH/src/$(dirname "$PACKAGE_NAME")" - ln -s "$CI_PROJECT_DIR" "$GOPATH/src/$PACKAGE_NAME" - cd "$GOPATH/src/$PACKAGE_NAME" - - dep ensure -v unit_tests: stage: test -- GitLab