2019-06-11 10:31:16 +00:00
|
|
|
stages:
|
|
|
|
- build
|
|
|
|
|
2019-06-11 10:08:46 +00:00
|
|
|
variables:
|
|
|
|
IMAGE_NAME: thallian/alpine-s6
|
2020-12-10 17:52:36 +00:00
|
|
|
DOWNSTREAM_PROJECTS: "11 12 14 15 17 18"
|
2019-06-11 10:08:46 +00:00
|
|
|
|
|
|
|
build:
|
|
|
|
stage: build
|
|
|
|
script:
|
2019-06-11 10:50:12 +00:00
|
|
|
- docker login -u $DOCKER_USER -p $DOCKER_PASSWORD $DOCKER_REGISTRY
|
2022-02-12 14:32:33 +00:00
|
|
|
- docker build -t $IMAGE_NAME:$CI_COMMIT_SHA .
|
|
|
|
- docker build -t $IMAGE_NAME:$CI_COMMIT_REF_NAME .
|
|
|
|
- docker build -t $IMAGE_NAME:latest .
|
|
|
|
- docker push $IMAGE_NAME:$CI_COMMIT_SHA
|
|
|
|
- docker push $IMAGE_NAME:$CI_COMMIT_REF_NAME
|
|
|
|
- docker push $IMAGE_NAME:latest
|
2020-12-10 17:52:36 +00:00
|
|
|
- |
|
|
|
|
for proj in $DOWNSTREAM_PROJECTS; do
|
|
|
|
curl --request POST --form "token=$CI_JOB_TOKEN" --form ref=master $CI_API_V4_URL/projects/$proj/trigger/pipeline
|
|
|
|
done
|