Commit 14ddd794 authored by Daniele Venzano's avatar Daniele Venzano

Use base image

parent 9dedec44
Pipeline #7841 canceled with stages
in 41 seconds
......@@ -5,19 +5,17 @@ stages:
- deploy
variables:
VERSION: $CI_PIPELINE_ID
VERSION: 7375
REPOSITORY: zapps
image: docker:latest
before_script:
- mkdir -p $HOME/.docker
- echo $DOCKER_AUTH_CONFIG > $HOME/.docker/config.json
build:boinc:
stage: build
test:build:
stage: test
script:
- docker build -t ${REPOSITORY}/boinc:${VERSION} docker/boinc
- docker build --build-arg VERSION=${VERSION} -t ${REPOSITORY}/boinc:${VERSION} boinc
build:json:
image: python:3-alpine
......@@ -36,10 +34,10 @@ test:json:
script:
- python /scripts/validate.py ${ZOE_VALIDATION_URL} boinc.json
push:all:
stage: push
.build_template: &build_def
stage: build
script:
- /scripts/distribute_docker_image.sh ${REPOSITORY}/boinc:${VERSION}
- docker -H ${BUILD_HOST}.containers.bigfoot.eurecom.fr:2375 $DOCKER_TLS_OPTIONS build --build-arg VERSION=${VERSION} -t ${REPOSITORY}/boinc:${VERSION} boinc/
only:
- master
......@@ -65,3 +63,83 @@ deploy:json:
only:
- master
build:bf7:
<<: *build_def
variables:
BUILD_HOST: bf7
build:bf8:
<<: *build_def
variables:
BUILD_HOST: bf8
build:bf9:
<<: *build_def
variables:
BUILD_HOST: bf9
build:bf10:
<<: *build_def
variables:
BUILD_HOST: bf10
build:bf12:
<<: *build_def
variables:
BUILD_HOST: bf12
build:bf13:
<<: *build_def
variables:
BUILD_HOST: bf13
build:bf14:
<<: *build_def
variables:
BUILD_HOST: bf14
build:bf15:
<<: *build_def
variables:
BUILD_HOST: bf15
build:bf16:
<<: *build_def
variables:
BUILD_HOST: bf16
build:bf17:
<<: *build_def
variables:
BUILD_HOST: bf17
build:bf18:
<<: *build_def
variables:
BUILD_HOST: bf18
build:bf19:
<<: *build_def
variables:
BUILD_HOST: bf19
build:bf20:
<<: *build_def
variables:
BUILD_HOST: bf20
build:bf21:
<<: *build_def
variables:
BUILD_HOST: bf21
build:bf22:
<<: *build_def
variables:
BUILD_HOST: bf22
build:deepfoot1:
<<: *build_def
variables:
BUILD_HOST: deepfoot1
FROM ubuntu:14.04
ARG VERSION=test
FROM zapps/base:${VERSION}
MAINTAINER Daniele Venzano <venza@brownhat.org>
......@@ -12,3 +13,4 @@ WORKDIR /data
COPY files/cc_config.xml /data
CMD /usr/bin/boinc --abort_jobs_on_exit --exit_when_idle --fetch_minimal_work --attach_project ${PROJECT_URL} ${PROJECT_KEY}
#!/usr/bin/env bash
set -e
if [ ! -d docker ]; then
exit
fi
REPOSITORY=${REPOSITORY:-zapps}
DOCKER_REGISTRY=${DOCKER_REGISTRY:-docker-registry:5000}
VERSION=${VERSION:-`date +%Y%m%d%H%M%S`}
built_images=''
for d in `find docker -mindepth 1 -maxdepth 1 -type d -printf '%f '`; do
pushd docker/${d}
docker build -t ${DOCKER_REGISTRY}/${REPOSITORY}/${d}:${VERSION} .
docker push ${DOCKER_REGISTRY}/${REPOSITORY}/${d}:${VERSION}
popd
built_images+="${DOCKER_REGISTRY}/${REPOSITORY}/${d}:${VERSION}\n"
done
echo "-------------END SCRIPT-----------------"
echo "Images built:"
printf ${built_images}
echo
Markdown is supported
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