Skip to content
Snippets Groups Projects
Commit bc6d3fa9 authored by Bc. Sergei Shestakov's avatar Bc. Sergei Shestakov
Browse files

Update .gitlab-ci.yml file

parent 73320efe
No related branches found
No related tags found
No related merge requests found
Pipeline #117466 passed
......@@ -7,7 +7,8 @@ variables:
DOCKER_DRIVER: overlay2
services:
- docker:20.10.16-dind
- name: docker:20.10.16-dind
command: ["--experimental", "--registry-mirror=https://registry.gitlab.fel.cvut.cz"]
build:
stage: build
......@@ -15,6 +16,8 @@ build:
script:
- docker info
- docker build -t $IMAGE_NAME:${CI_COMMIT_SHORT_SHA} .
- echo $CI_REGISTRY_PASSWORD | docker login -u $CI_REGISTRY_USER --password-stdin $CI_REGISTRY
- docker push $IMAGE_NAME:${CI_COMMIT_SHORT_SHA}
only:
- main
......@@ -22,7 +25,8 @@ push:
stage: push
image: docker:20.10.16
script:
- docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY
- echo $CI_REGISTRY_PASSWORD | docker login -u $CI_REGISTRY_USER --password-stdin $CI_REGISTRY
- docker pull $IMAGE_NAME:${CI_COMMIT_SHORT_SHA}
- docker push $IMAGE_NAME:${CI_COMMIT_SHORT_SHA}
only:
- main
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment