From ec1d50c9b3d4c69e8ab06297e1e8616bbd87df53 Mon Sep 17 00:00:00 2001 From: Sebastian Hugentobler Date: Thu, 31 Aug 2017 14:44:47 +0200 Subject: [PATCH] us gitlab docker registry --- .gitlab-ci.yml | 10 ++++++++++ Dockerfile | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) create mode 100644 .gitlab-ci.yml diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 0000000..447392a --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,10 @@ +build: + image: docker:latest + services: + - docker:dind + stage: build + script: + - docker login -u gitlab-ci-token -p $CI_JOB_TOKEN $CI_REGISTRY + - docker build --pull --tag $CI_REGISTRY_IMAGE:latest --tag $CI_REGISTRY_IMAGE:$CI_COMMIT_SHA . + - docker push $CI_REGISTRY_IMAGE:latest + - docker push $CI_REGISTRY_IMAGE:$CI_COMMIT_SHA diff --git a/Dockerfile b/Dockerfile index 2578b51..e94efc4 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,3 +1,3 @@ -FROM quay.io/thallian/alpine-s6:latest +FROM registry.gitlab.com/thallian/docker-alpine-s6:latest ADD /rootfs /