shad-go/.releaser-ci.yml

71 lines
2.1 KiB
YAML
Raw Normal View History

2020-01-31 19:03:57 +00:00
check:
image: eu.gcr.io/shad-ts/grader/go-build
2021-03-18 21:08:54 +00:00
variables:
DOCKER_HOST: tcp://docker:2375/
DOCKER_TLS_CERTDIR: ""
APP_HOST: docker
2021-03-22 19:20:48 +00:00
# services:
#- docker:dind
2020-01-31 19:03:57 +00:00
script:
2020-03-19 12:46:57 +00:00
- rm -rf lectures/ # do not run tests from lecture examples
2020-04-09 09:07:26 +00:00
- golangci-lint run --build-tags private,solution ./...
2021-03-22 19:20:48 +00:00
#- go test -v -tags private,solution ./...
#- go test -v -race -tags private,solution ./...
2021-03-31 22:47:21 +00:00
- go test $(go list -tags private,solution ./... | grep -v /dockertest | grep -v /foolsday3) -tags private,solution -v ./...
2021-03-22 19:20:48 +00:00
- go test $(go list -tags private,solution ./... | grep -v /dockertest) -tags private,solution -v -race ./...
2020-01-31 19:03:57 +00:00
rebuild-base-image:
tags:
- docker
when: manual
script:
- docker build -f build.docker -t eu.gcr.io/shad-ts/grader/go-build .
- docker push eu.gcr.io/shad-ts/grader/go-build:latest
2020-02-01 00:35:28 +00:00
deploy:
2020-01-31 19:03:57 +00:00
only:
- master
tags:
- docker
script:
2020-02-01 00:35:28 +00:00
- docker pull eu.gcr.io/shad-ts/grader/go-build:latest
- docker build -f testenv.docker -t eu.gcr.io/shad-ts/grader/go .
- docker push eu.gcr.io/shad-ts/grader/go:latest
2020-02-01 20:57:53 +00:00
build-slides:
2020-02-01 20:16:15 +00:00
only:
- master
tags:
- docker
script:
- docker build lectures -t eu.gcr.io/shad-ts/go-lectures
- docker push eu.gcr.io/shad-ts/go-lectures
2020-02-01 00:35:28 +00:00
push-to-public:
2020-02-01 00:37:41 +00:00
stage: .post
2020-02-01 00:35:28 +00:00
image: eu.gcr.io/shad-ts/grader/go
only:
- master
script:
2020-02-01 00:54:20 +00:00
- git remote rm public || true
2020-02-01 00:52:09 +00:00
- git remote add -f public https://prime:${CI_PUSH_TOKEN}@gitlab.com/slon/shad-go.git
2020-02-01 00:35:28 +00:00
- git config --global user.email 'prime@yandex-team.ru'
- git config --global user.name 'Fedor Korotkiy'
2020-02-01 00:46:34 +00:00
- git fetch public
2020-02-01 00:54:20 +00:00
- git branch -D public || true
2020-02-01 00:46:34 +00:00
- git branch public public/master
2020-02-01 01:05:29 +00:00
- testtool export --push --move-to-master=false
2020-02-21 22:51:17 +00:00
- curl -F token=$TESTER_TOKEN https://go.manytask.org/api/sync_task_columns
2020-02-01 20:57:53 +00:00
deploy-slides:
stage: .post
only:
- master
tags:
- web
script:
- docker stop -t0 go-lectures || true
- docker rm go-lectures || true
- docker pull eu.gcr.io/shad-ts/go-lectures
- docker run -p 3999:3999 -d --name go-lectures --restart=always eu.gcr.io/shad-ts/go-lectures