mirror of
https://github.com/f-droid/fdroidserver.git
synced 2025-11-04 22:40:29 +03:00
gitlab-ci: publish buildserver image to Docker Registry
This commit is contained in:
parent
f20d3d249a
commit
839f5b109a
1 changed files with 22 additions and 0 deletions
|
|
@ -529,3 +529,25 @@ pages:
|
||||||
needs: ["Build documentation"]
|
needs: ["Build documentation"]
|
||||||
rules:
|
rules:
|
||||||
- if: '$CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH' # only publish pages on default (master) branch
|
- if: '$CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH' # only publish pages on default (master) branch
|
||||||
|
|
||||||
|
|
||||||
|
docker:
|
||||||
|
dependencies:
|
||||||
|
- fdroid build
|
||||||
|
only:
|
||||||
|
changes:
|
||||||
|
- .gitlab-ci.yml
|
||||||
|
- makebuildserver
|
||||||
|
- buildserver/*
|
||||||
|
image: docker:git
|
||||||
|
services:
|
||||||
|
- docker:dind
|
||||||
|
variables:
|
||||||
|
TEST_IMAGE: registry.gitlab.com/$CI_PROJECT_NAMESPACE/${CI_PROJECT_NAME}:$CI_BUILD_REF_NAME
|
||||||
|
RELEASE_IMAGE: registry.gitlab.com/$CI_PROJECT_NAMESPACE/${CI_PROJECT_NAME}:buildserver
|
||||||
|
script:
|
||||||
|
- cd buildserver
|
||||||
|
- docker build -t $TEST_IMAGE --build-arg GIT_REV_PARSE_HEAD=$(git rev-parse HEAD) .
|
||||||
|
- docker tag $TEST_IMAGE $RELEASE_IMAGE
|
||||||
|
- echo $CI_BUILD_TOKEN | docker login -u gitlab-ci-token --password-stdin registry.gitlab.com
|
||||||
|
- docker push $RELEASE_IMAGE
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue