Skip to content
Snippets Groups Projects
Commit 856c8c53 authored by Vaclav Sraier's avatar Vaclav Sraier Committed by Aleš Mrázek
Browse files

CI containers: README and naming

parent acb91dd2
No related merge requests found
...@@ -2,27 +2,30 @@ stages: ...@@ -2,27 +2,30 @@ stages:
- build - build
- check - check
image: $CI_REGISTRY/knot/knot-resolver-manager/ci/devenv:latest image: $CI_REGISTRY/knot/knot-resolver-manager/devenv:latest
build: # Ideally, the CI would build it's own container and use it afterwards. This workflow should be supported,
image: docker:19.03.12 # at least according to the GitLab documentation:
stage: build # https://gitlab.nic.cz/help/user/packages/container_registry/index#container-registry-examples-with-gitlab-cicd
services: # Sadly, it does not work on our infrastructure. I did not however test it thoroughly and/or consulted it with
- docker:19.03.12-dind # anyone else. So it might be fixable. For now, let's leave the config here and we might fix it in the future.
variables: #
IMAGE_TAG: $CI_REGISTRY/knot/knot-resolver-manager/ci/devenv:latest # build:
script: # image: docker:19.03.12
- docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY # stage: build
- docker build -t $IMAGE_TAG ci/devenv # services:
- docker push $IMAGE_TAG # - docker:19.03.12-dind
# variables:
# IMAGE_TAG: $CI_REGISTRY/knot/knot-resolver-manager/ci/devenv:latest
# script:
# - docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY
# - docker build -t $IMAGE_TAG ci/devenv
# - docker push $IMAGE_TAG
# FIXME - use custom Docker image, so that we don't rebuild it all every single time # FIXME - use custom Docker image, so that we don't rebuild it all every single time
lint: lint:
image: debian:latest image: debian:latest
stage: check stage: check
variables:
# Python by default uses ascii encoding, which does not work, because source files are in UTF-8. Here is a potential solution, but for newer Python https://www.python.org/dev/peps/pep-0540/
LC_ALL: C.UTF-8
cache: cache:
key: "check:always-the-same-cache" key: "check:always-the-same-cache"
......
Docker Build
------------
```
$ docker build --no-cache -t registry.nic.cz/knot/knot-resolver-manager/devenv:latest devenv
$ docker login registry.nic.cz
$ docker push registry.nic.cz/knot/knot-resolver-manager/devenv:latest
```
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