From fc2b16a678ee749f239d569fc8da54566b139b53 Mon Sep 17 00:00:00 2001 From: Hector Date: Mon, 19 Jun 2023 19:26:57 +0100 Subject: [PATCH] use golang image for cicd --- .gitlab-ci.yml | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 600f802..a6c8c04 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -2,10 +2,8 @@ stages: - test - build -# .go_template: -# image: golang:latest -# before_script: -# - make download +.go_template: + image: golang:latest # .docker_template: # image: docker:stable @@ -17,24 +15,32 @@ stages: # - docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY dependencies: + extends: .go_template stage: test script: - make check/dependencies format: + extends: .go_template stage: test script: - make check/fmt test: + extends: .go_template stage: test script: - make test build: + extends: .go_template stage: build script: - make build + artifacts: + paths: + - build/* + expire_in: 1 day # build: # extends: .go_template