Added build pipeline
This commit is contained in:
parent
94c2879cc0
commit
3c73414288
25
.gitlab-ci.yml
Normal file
25
.gitlab-ci.yml
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
image: docker:dind
|
||||||
|
|
||||||
|
services:
|
||||||
|
- name: docker:dind
|
||||||
|
entrypoint: ["env", "-u", "DOCKER_HOST"]
|
||||||
|
command: ["dockerd-entrypoint.sh"]
|
||||||
|
variables:
|
||||||
|
DOCKER_HOST: tcp://docker:2375/
|
||||||
|
DOCKER_DRIVER: overlay2
|
||||||
|
DOCKER_TLS_CERTDIR: ""
|
||||||
|
|
||||||
|
before_script:
|
||||||
|
- echo $CI_REGISTRY_PASSWORD | docker login -u $CI_REGISTRY_USER --password-stdin $CI_REGISTRY
|
||||||
|
|
||||||
|
|
||||||
|
build:
|
||||||
|
stage: build
|
||||||
|
script:
|
||||||
|
- docker build . -t frontend:$CI_COMMIT_SHORT_SHA
|
||||||
|
- docker tag frontend:$CI_COMMIT_SHORT_SHA $CI_REGISTRY/taskboard/frontend:$CI_COMMIT_SHORT_SHA
|
||||||
|
- docker push $CI_REGISTRY/taskboard/frontend:$CI_COMMIT_SHORT_SHA
|
||||||
|
- docker tag frontend:$CI_COMMIT_SHORT_SHA $CI_REGISTRY/taskboard/frontend:latest
|
||||||
|
- docker push $CI_REGISTRY/taskboard/frontend:latest
|
||||||
|
tags:
|
||||||
|
- frontend
|
Loading…
x
Reference in New Issue
Block a user