-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy path.gitlab-ci.yml
More file actions
45 lines (36 loc) · 939 Bytes
/
.gitlab-ci.yml
File metadata and controls
45 lines (36 loc) · 939 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
---
variables:
UTIL_FLAKE: git+ssh://git@tsa04.isa.ru/util/nix
BUILD_FLAKE: "${UTIL_FLAKE}#build"
DOCKER_FLAKE: "${UTIL_FLAKE}#buildDocker"
stages:
- build
- build-docker-image
build:
stage: build
rules:
- if: $CI_SERVER_HOST == "tsa04.isa.ru"
script:
- nix run "$BUILD_FLAKE" -- -S -i . -C semvectors
- nix run "$BUILD_FLAKE" -- -S -i .#doc_enc_train -C semvectors
- nix run "$BUILD_FLAKE" -- -i .#doc_enc_cu11
artifacts:
reports:
# build.env is created by BUILD_FLAKE when -S switch is presented
dotenv: build.env
tags:
- nix
build-docker-image:
stage: build-docker-image
rules:
- if: $CI_COMMIT_MESSAGE =~ /\[build-docker\]/
script:
- nix run "$DOCKER_FLAKE" --
-i ".#trainDockerImage"
-u "$CI_REGISTRY_USER"
-p "$CI_REGISTRY_PASSWORD"
-r "$CI_REGISTRY"
-ri "$CI_REGISTRY_IMAGE/train"
-t "$APP_VERSION"
tags:
- nix