mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-13 05:44:24 +00:00
adding deploy doc stage
This commit is contained in:
parent
8e6f2d4355
commit
7763bddc80
@ -11,10 +11,10 @@
|
|||||||
|
|
||||||
|
|
||||||
stages:
|
stages:
|
||||||
- build-doc
|
|
||||||
- deploy-doc
|
|
||||||
- test
|
- test
|
||||||
- deploy
|
- deploy
|
||||||
|
- build-doc
|
||||||
|
- deploy-doc
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -31,6 +31,18 @@ test:php-7:
|
|||||||
image: chill/ci-image:php-7
|
image: chill/ci-image:php-7
|
||||||
script: phpunit
|
script: phpunit
|
||||||
|
|
||||||
|
|
||||||
|
deploy-packagist:
|
||||||
|
stage: deploy
|
||||||
|
image: chill/ci-image:php-7
|
||||||
|
before_script:
|
||||||
|
# test that PACKAGIST USERNAME and PACKAGIST_TOKEN variable are set
|
||||||
|
- if [ -z ${PACKAGIST_USERNAME+x} ]; then echo "Please set PACKAGIST_USERNAME variable"; exit -1; fi
|
||||||
|
- if [ -z ${PACKAGIST_TOKEN+x} ]; then echo "Please set PACKAGIST_TOKEN variable"; exit -1; fi
|
||||||
|
script:
|
||||||
|
- STATUSCODE=$(curl -XPOST -H'content-type:application/json' "https://packagist.org/api/update-package?username=$PACKAGIST_USERNAME&apiToken=$PACKAGIST_TOKEN" -d"{\"repository\":{\"url\":\"$CI_PROJECT_URL.git\"}}" --silent --output /dev/stderr --write-out "%{http_code}")
|
||||||
|
- if [ $STATUSCODE = "202" ]; then exit 0; else exit $STATUSCODE; fi
|
||||||
|
|
||||||
# deploy documentation
|
# deploy documentation
|
||||||
api-doc-build:
|
api-doc-build:
|
||||||
stage: build-doc
|
stage: build-doc
|
||||||
@ -47,14 +59,4 @@ api-doc-build:
|
|||||||
only:
|
only:
|
||||||
- master
|
- master
|
||||||
- tags
|
- tags
|
||||||
|
|
||||||
deploy-packagist:
|
|
||||||
stage: deploy
|
|
||||||
image: chill/ci-image:php-7
|
|
||||||
before_script:
|
|
||||||
# test that PACKAGIST USERNAME and PACKAGIST_TOKEN variable are set
|
|
||||||
- if [ -z ${PACKAGIST_USERNAME+x} ]; then echo "Please set PACKAGIST_USERNAME variable"; exit -1; fi
|
|
||||||
- if [ -z ${PACKAGIST_TOKEN+x} ]; then echo "Please set PACKAGIST_TOKEN variable"; exit -1; fi
|
|
||||||
script:
|
|
||||||
- STATUSCODE=$(curl -XPOST -H'content-type:application/json' "https://packagist.org/api/update-package?username=$PACKAGIST_USERNAME&apiToken=$PACKAGIST_TOKEN" -d"{\"repository\":{\"url\":\"$CI_PROJECT_URL.git\"}}" --silent --output /dev/stderr --write-out "%{http_code}")
|
|
||||||
- if [ $STATUSCODE = "202" ]; then exit 0; else exit $STATUSCODE; fi
|
|
||||||
|
@ -6,7 +6,7 @@ source:
|
|||||||
|
|
||||||
exclude:
|
exclude:
|
||||||
- vendor/*
|
- vendor/*
|
||||||
- Resource/test/*
|
- Resources/test/*
|
||||||
|
|
||||||
title: Chill EventBundle
|
title: Chill EventBundle
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user