From 0f79fee46b391b7995309403baa92fca036c90f9 Mon Sep 17 00:00:00 2001 From: Scott Charlton Date: Sat, 18 Jan 2020 23:57:55 -0700 Subject: [PATCH 1/3] Added .gitlab-ci.yml --- .gitlab-ci.yml | 51 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 .gitlab-ci.yml diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 00000000..77e8364c --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,51 @@ +# +# https://code.chs.usgs.gov/coupled/subtrees/phreeqc3-doc +# +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-doc + ## and set GROUP to coupled before merge + only: + refs: + - master + variables: + - $GROUP + + ## Downstream Projects + ## triggers and ids are stored at the group level + ## iphreeqc https://code.chs.usgs.gov/coupled/iphreeqc + ## iphreeqccom https://code.chs.usgs.gov/coupled/iphreeqccom + ## phast3-doc https://code.chs.usgs.gov/coupled/subtrees/phast3-doc + ## phreeqc3 https://code.chs.usgs.gov/coupled/phreeqc3 + script: + - echo triggering iphreeqc + - curl -X POST -F token=${IPHREEQC_TRIGGER} -F ref=master https://code.chs.usgs.gov/api/v4/projects/${IPHREEQC_ID}/trigger/pipeline + - echo triggering iphreeqccom + - curl -X POST -F token=${IPHREEQCCOM_TRIGGER} -F ref=master https://code.chs.usgs.gov/api/v4/projects/${IPHREEQCCOM_ID}/trigger/pipeline + - echo triggering phast3-doc PHAST3_DOC_TRIGGER PHAST3_DOC_ID + - curl -X POST -F token=${PHAST3_DOC_TRIGGER} -F ref=master https://code.chs.usgs.gov/api/v4/projects/${PHAST3_DOC_ID}/trigger/pipeline + - echo triggering phreeqc3 PHREEQC3_TRIGGER PHREEQC3_ID + - curl -X POST -F token=${PHREEQC3_TRIGGER} -F ref=master https://code.chs.usgs.gov/api/v4/projects/${PHREEQC3_ID}/trigger/pipeline + + ## Upstream Projects + ## none From 206bd3e73665fb802ddb0b0ce9150353eb86b3cd Mon Sep 17 00:00:00 2001 From: Scott Charlton Date: Mon, 27 Jan 2020 14:36:36 -0700 Subject: [PATCH 2/3] [phreeqc3] Testing subtree merges --- .gitlab-ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 77e8364c..1cdd6c7c 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,5 +1,6 @@ # # https://code.chs.usgs.gov/coupled/subtrees/phreeqc3-doc +# SRC 2020-01-27T14:33:39-07:00 # image: buildpack-deps:bionic-scm From 001a6b42eccc66da2994b511e32e93f1ece0f98b Mon Sep 17 00:00:00 2001 From: Scott Charlton Date: Tue, 28 Jan 2020 10:05:51 -0700 Subject: [PATCH 3/3] [phreeqci] Testing subtree merges --- .gitlab-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 1cdd6c7c..704ba16a 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,6 +1,6 @@ # # https://code.chs.usgs.gov/coupled/subtrees/phreeqc3-doc -# SRC 2020-01-27T14:33:39-07:00 +# SRC 2020-01-28T10:03:39-07:00 # image: buildpack-deps:bionic-scm