Commit ed0579f3 authored by Ulf Seltmann's avatar Ulf Seltmann
Browse files

refactored tag management

parent ac71750b
Pipeline #192 failed with stages
in 20 seconds
......@@ -9,8 +9,9 @@ httpd_image:
- docker:dind
script: |
mkdir -p ~/.docker && echo "$DOCKER_AUTH_CONFIG" >~/.docker/config.json
export suffix=`expr $CI_COMMIT_TAG ':' 'httpd/\2.4-\(.*\)'`
export suffix=`expr $CI_COMMIT_TAG ':' 'httpd/2.4-\(.*\)'`
docker build --pull -t services.ub.uni-leipzig.de:11443/bdd_dev/vufind/httpd:2.4-${suffix} -f dockerfiles/Dockerfile.httpd:2.4 .
docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/httpd:2.4-${suffix}
for tag in "latest" "2.4"; do
docker tag services.ub.uni-leipzig.de:11443/bdd_dev/vufind/httpd:2.4-${suffix} services.ub.uni-leipzig.de:11443/bdd_dev/vufind/httpd:${tag}
docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/httpd:${tag}
......@@ -27,13 +28,15 @@ httpd_vufind1_image:
image: docker:latest
services:
- docker:dind
script:
- mkdir -p ~/.docker && echo "$DOCKER_AUTH_CONFIG" >~/.docker/config.json
- export tag=`expr ${CI_COMMIT_TAG} ':' '^httpd-vufind1/\(.*\)$'`
- docker build --pull -t services.ub.uni-leipzig.de:11443/bdd_dev/vufind/httpd-vufind1:latest -f dockerfiles/Dockerfile.httpd-vufind1 .
- docker tag services.ub.uni-leipzig.de:11443/bdd_dev/vufind/httpd-vufind1:latest services.ub.uni-leipzig.de:11443/bdd_dev/vufind/httpd-vufind1:${tag}
- docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/httpd-vufind1:${tag}
- docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/httpd-vufind1:latest
script: |
mkdir -p ~/.docker && echo "$DOCKER_AUTH_CONFIG" >~/.docker/config.json
export tag=`expr ${CI_COMMIT_TAG} ':' '^httpd-vufind1/2.4-\(.*\)$'`
docker build --pull -t services.ub.uni-leipzig.de:11443/bdd_dev/vufind/httpd-vufind1:2.4-${suffix} -f dockerfiles/Dockerfile.httpd-vufind1:2.4 .
docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/httpd-vufind1:2.4-${suffix}
for tag in "latest" "2.4"; do
docker tag services.ub.uni-leipzig.de:11443/bdd_dev/vufind/httpd-vufind1:2.4-${suffix} services.ub.uni-leipzig.de:11443/bdd_dev/vufind/httpd-vufind1:${tag}
docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/httpd-vufind1:${tag}
done
tags:
- docker
only:
......@@ -46,13 +49,16 @@ nginx_image:
image: docker:latest
services:
- docker:dind
script:
- mkdir -p ~/.docker && echo "$DOCKER_AUTH_CONFIG" >~/.docker/config.json
- export tag=`expr ${CI_COMMIT_TAG} ':' '^nginx/\(.*\)$'`
- docker build --pull -t services.ub.uni-leipzig.de:11443/bdd_dev/vufind/nginx:latest -f dockerfiles/Dockerfile.nginx .
- docker tag services.ub.uni-leipzig.de:11443/bdd_dev/vufind/nginx:latest services.ub.uni-leipzig.de:11443/bdd_dev/vufind/nginx:${tag}
- docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/nginx:${tag}
- docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/nginx:latest
script: |
mkdir -p ~/.docker && echo "$DOCKER_AUTH_CONFIG" >~/.docker/config.json
export suffix=`expr ${CI_COMMIT_TAG} ':' '^nginx/1.13-\(.*\)$'`
docker build --pull -t services.ub.uni-leipzig.de:11443/bdd_dev/vufind/nginx:1.13-${suffix} -f dockerfiles/Dockerfile.nginx:1.13 .
docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/nginx:${tag}-${suffix}
for tag in "latest" "1.13"; do
docker tag services.ub.uni-leipzig.de:11443/bdd_dev/vufind/nginx:1.13-${suffix} services.ub.uni-leipzig.de:11443/bdd_dev/vufind/nginx:${tag}
docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/nginx:${tag}
done
tags:
- docker
only:
......@@ -65,16 +71,17 @@ php_7_image:
image: docker:latest
services:
- docker:dind
script:
- mkdir -p ~/.docker && echo "$DOCKER_AUTH_CONFIG" >~/.docker/config.json
- export suffix=`expr ${CI_COMMIT_TAG} ':' '^php/7-\(.*\)$'`
- for tag in 7 7-debug; do docker build -t services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:${tag}-${suffix} -f dockerfiles/Dockerfile.php:${tag} .; done
- for tag in 7 7-debug; do docker tag services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:${tag}-${suffix} services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:${tag}-${suffix}; done
- docker tag services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:7-${suffix} services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:7
- docker tag services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:7-debug-${suffix} services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:7-debug
- docker tag services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:7 services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:latest
- for tag in 7 7-debug; do docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:${tag}; docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:${tag}-${suffix}; done
- docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:latest
script: |
mkdir -p ~/.docker && echo "$DOCKER_AUTH_CONFIG" >~/.docker/config.json
export suffix=`expr ${CI_COMMIT_TAG} ':' '^php/7-\(.*\)$'`
for tag in 7 7-debug; do
docker build -t services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:${tag}-${suffix} -f dockerfiles/Dockerfile.php:${tag} .
docker tag services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:${tag}-${suffix} services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:${tag}
docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:${tag}-${suffix}
docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:${tag}
done
docker tag services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:7-${suffix} services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:latest
docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:latest
tags:
- docker
only:
......@@ -87,16 +94,16 @@ php_5_image:
image: docker:latest
services:
- docker:dind
script:
- mkdir -p ~/.docker && echo "$DOCKER_AUTH_CONFIG" >~/.docker/config.json
- export suffix=`expr ${CI_COMMIT_TAG} ':' '^php/5-\(.*\)$'`
- for tag in 5 5-debug; do docker build -t services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:${tag}-${suffix} -f dockerfiles/Dockerfile.php:${tag} .; done
- for tag in 5 5-debug; do docker tag services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:${tag}-${suffix} services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:${tag}-${suffix}; done
- docker tag services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:5-${suffix} services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:5
- docker tag services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:5-debug-${suffix} services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:5-debug
- docker tag services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:5 services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:latest
- for tag in 5 5-debug; do docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:${tag}; docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:${tag}-${suffix}; done
- docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:latest
script: |
mkdir -p ~/.docker && echo "$DOCKER_AUTH_CONFIG" >~/.docker/config.json
export suffix=`expr ${CI_COMMIT_TAG} ':' '^php/5-\(.*\)$'`
for tag in 5 5-debug; do
docker build -t services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:${tag}-${suffix} -f dockerfiles/Dockerfile.php:${tag} .
docker tag services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:${tag}-${suffix} services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:${tag}
docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:${tag}-${suffix}
docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php:${tag}
done
tags:
- docker
only:
......@@ -109,13 +116,13 @@ php_5_vufind1_image:
image: docker:latest
services:
- docker:dind
script:
- mkdir -p ~/.docker && echo "$DOCKER_AUTH_CONFIG" >~/.docker/config.json
- export suffix=`expr ${CI_COMMIT_TAG} ':' '^php-vufind1/5.3-(.*\)$'`
- docker build -t services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php-vufind1:5.3-debug-${suffix} -f dockerfiles/Dockerfile.php-vufind1:5.3-debug .
- docker tag services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php-vufind1:5.3-debug-${suffix} services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php-vufind1:5.3-debug
- docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php-vufind1:5.3-debug-${suffix}
- docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php-vufind1:5.3-debug
script: |
mkdir -p ~/.docker && echo "$DOCKER_AUTH_CONFIG" >~/.docker/config.json
export suffix=`expr ${CI_COMMIT_TAG} ':' '^php-vufind1/5.3-(.*\)$'`
docker build -t services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php-vufind1:5.3-debug-${suffix} -f dockerfiles/Dockerfile.php-vufind1:5.3-debug .
docker tag services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php-vufind1:5.3-debug-${suffix} services.ub.uni-leipzig.de:11443/bdd_dev/vufind/php-vufind1:5.3-debug
docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/nginx:5.3-debug-${suffix}
docker push services.ub.uni-leipzig.de:11443/bdd_dev/vufind/nginx:5.3-debug
tags:
- docker
only:
......
FROM httpd:alpine
FROM httpd:2.4-alpine
ENTRYPOINT [ "/docker-entrypoint" ]
CMD ["httpd-foreground"]
......
FROM httpd:alpine
FROM httpd:2.4-alpine
ENTRYPOINT [ "/docker-entrypoint" ]
CMD ["httpd-foreground"]
......
FROM nginx:alpine
FROM nginx:1.13-alpine
ENTRYPOINT [ "/docker-entrypoint" ]
CMD [ "nginx", "-g", "daemon off;" ]
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment