From 93319e874eef817ad41a5ae56940b9a3df5c58ef Mon Sep 17 00:00:00 2001 From: s3lph Date: Tue, 10 Jul 2018 20:25:34 +0200 Subject: [PATCH] Added a CI job that builds a docker image and pushes it to the project's registry. --- .gitlab-ci.yml | 8 ++++++++ doc | 2 +- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 9adc47d..002cfa4 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -4,6 +4,7 @@ image: s3lph/matemat-ci:20180619-01 stages: - test - codestyle +- deploy test: stage: test @@ -18,3 +19,10 @@ codestyle: - pip3 install -r requirements.txt - pycodestyle matemat # - mypy --ignore-missing-imports --strict -p matemat + +docker_build_push: + stage: deploy + script: + - docker build -t "s3lph/matemat:$(git rev-parse HEAD)" . + - docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_TOKEN registry.gitlab.com + - docker push registry.gitlab.com/s3lph/matemat diff --git a/doc b/doc index 51e9404..9634785 160000 --- a/doc +++ b/doc @@ -1 +1 @@ -Subproject commit 51e940460ddbaebb7f2ffc48d00d9ef19cf8d33f +Subproject commit 9634785e5621b324f72598b3cee83bbc45c25d7b