mirror of
https://git.gfz-potsdam.de/naaice/iphreeqc.git
synced 2025-12-16 16:44:49 +01:00
Added .gitlab-ci.yml
This commit is contained in:
parent
5947da9065
commit
84865ad5ac
45
.gitlab-ci.yml
Normal file
45
.gitlab-ci.yml
Normal file
@ -0,0 +1,45 @@
|
|||||||
|
#
|
||||||
|
# https://code.chs.usgs.gov/coupled/subtrees/phreeqc3-src-common
|
||||||
|
#
|
||||||
|
image: buildpack-deps:bionic-scm
|
||||||
|
|
||||||
|
stages:
|
||||||
|
- trigger
|
||||||
|
|
||||||
|
before_script:
|
||||||
|
- eval $(ssh-agent -s)
|
||||||
|
- echo "${SSH_PRIVATE_KEY_ENC}" | base64 --decode | tr -d '\r' | ssh-add -
|
||||||
|
- mkdir -p ~/.ssh
|
||||||
|
- chmod 700 ~/.ssh
|
||||||
|
- ssh-keyscan ${CI_SERVER_HOST} >> ~/.ssh/known_hosts
|
||||||
|
- chmod 644 ~/.ssh/known_hosts
|
||||||
|
- git config --global user.email "darth@empire.com"
|
||||||
|
- git config --global user.name "Darth Vader"
|
||||||
|
|
||||||
|
trigger-downstream:
|
||||||
|
stage: trigger
|
||||||
|
##
|
||||||
|
## Only run if on the master branch and the variable GROUP is set
|
||||||
|
##
|
||||||
|
## change this to
|
||||||
|
## only:
|
||||||
|
## - master@$GROUP/subtrees/phreeqc3-src-common
|
||||||
|
## and set GROUP to coupled before merge
|
||||||
|
only:
|
||||||
|
refs:
|
||||||
|
- master
|
||||||
|
variables:
|
||||||
|
- $GROUP
|
||||||
|
|
||||||
|
## Downstream Projects
|
||||||
|
## triggers and ids are stored at the group level
|
||||||
|
## phreeqc3-src https://code.chs.usgs.gov/coupled/subtrees/phreeqc3-src
|
||||||
|
## wphast https://code.chs.usgs.gov/coupled/wphast
|
||||||
|
script:
|
||||||
|
- echo triggering phreeqc3-src
|
||||||
|
- curl -X POST -F token=${PHREEQC3_SRC_TRIGGER} -F ref=master https://code.chs.usgs.gov/api/v4/projects/${PHREEQC3_SRC_ID}/trigger/pipeline
|
||||||
|
- echo triggering wphast
|
||||||
|
- curl -X POST -F token=${WPHAST_TRIGGER} -F ref=master https://code.chs.usgs.gov/api/v4/projects/${WPHAST_ID}/trigger/pipeline
|
||||||
|
|
||||||
|
## Upstream Projects
|
||||||
|
## none
|
||||||
Loading…
x
Reference in New Issue
Block a user