Commit a1b99987 authored by M4xw's avatar M4xw 🍗

Update .gitlab-ci.yml

parent 8319ad68
Pipeline #4755 passed with stage
in 3 minutes and 15 seconds
image: docker:latest
stages:
- publish
services:
- docker:dind
before_script:
- apk add --no-cache curl
- docker info
- docker login -u $USER -p $PASSWD
stable:
stage: publish
docker-build-master:
# Official docker image.
image: docker:latest
stage: build
services:
- docker:dind
before_script:
- docker login -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD" $CI_REGISTRY
script:
# Basically archived
#- docker build -t $USER/libnx:latest .
#- docker push $USER/libnx:latest
- "curl -X POST -F token=$TOKEN_RA -F ref=master https://git.m4xw.net/api/v4/projects/81/trigger/pipeline"
- docker build --build-arg branch=develop --pull -t "$CI_REGISTRY_IMAGE" .
- docker push "$CI_REGISTRY_IMAGE"
only:
- master
nightly:
stage: publish
docker-build:
# Official docker image.
image: docker:latest
stage: build
services:
- docker:dind
before_script:
- docker login -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD" $CI_REGISTRY
script:
- docker build --build-arg branch=develop -t $USER/libnx:nightly .
- docker push $USER/libnx:nightly
# Hack
- docker push $USER/libnx:latest
#- "curl -X POST -F token=$TOKEN_RA -F ref=develop https://git.m4xw.net/api/v4/projects/81/trigger/pipeline"
only:
- develop
- docker build --build-arg branch=develop --pull -t "$CI_REGISTRY_IMAGE:$CI_COMMIT_REF_SLUG" .
- docker push "$CI_REGISTRY_IMAGE:$CI_COMMIT_REF_SLUG"
except:
- master
Markdown is supported
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