-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.gitlab-ci.yml
59 lines (56 loc) · 1.29 KB
/
.gitlab-ci.yml
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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
variables:
PACKAGE_DEPLOY_ROOT: "/util/opt/anaconda/deployed-conda-envs"
HCC_APPS_DB_BCRF_PATH: "/work/HCC/BCRF/app_specific"
CONDA_OVERRIDE_CUDA: "12.2"
MAMBA_NO_BANNER: 1
stages:
- test
- deploy
test-swan:
stage: test
image: unlhcc/swan-build
variables:
ANACONDA_PREFIX: "/anaconda"
PY_VER: "3.8"
AP_VER: "0.9.1"
AC_VER: "1.7.2"
MINICONDA_VER: "4.10"
MAMBA_VER: "0.24"
HCC_APPS_DB_BCRF_PATH: "/tmp"
except:
- master
tags:
- swan
before_script:
- scripts/gitlabci-setup.sh
script:
- scripts/test_changed_packages.sh
retry: 2
deploy-swan:
stage: deploy
environment:
name: swan_production
url: https://swan.unl.edu
resource_group: production-swan
image: unlhcc/swan-build
variables:
ANACONDA_PREFIX: "/util/opt/anaconda/4.8/envs/anaconda-project-0.9.1"
DEPLOY_HOST: "SWAN"
only:
- master
tags:
- swan
before_script:
- eval $(ssh-agent -s) > /dev/null
- mkdir -p ~/.ssh
- chown 700 ~/.ssh
- echo $SSH_KNOWN_HOSTS > ~/.ssh/known_hosts
- chmod 644 ~/.ssh/known_hosts
- ssh-add <(echo "$SSH_PRIVATE_KEY" | base64 --decode)
script:
- cd $PACKAGE_DEPLOY_ROOT
- git checkout master
- git fetch
- git checkout $CI_COMMIT_SHA
- scripts/deploy_all_packages.sh
retry: 2