stages: - test - push test: stage: test image: golang:1.17 only: refs: - main - merge_requests script: - go get github.com/go-redis/redis/v8 - go test ./... push: stage: push rules: - if: $CI_COMMIT_TAG - if: '$CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH' script: - mkdir ~/.docker - echo "$DOCKER_AUTH_CONFIG" | tee ~/.docker/config.json | md5sum - sh build/ci/ci.sh publish