+ Pipelines for freechat prod and pipe versions

Both of these are behind 'only' flags to avoid pointless rebuilding
This commit is contained in:
shockrah 2021-06-07 10:42:50 -07:00
parent 7e166f5eac
commit c00ca1942a

View File

@ -1,7 +1,44 @@
get_vars: image: docker
stage: test
stages:
- default
variables:
USER: shockrah
before_script:
- docker login --username $USER --password $PASS
build-freechat-prod:
# Can't use variables section here due to the sub shell being invoked here
before_script:
- export VERSION="$(date +%d-%m-%Y)"
stage: default
only:
refs:
- master
changes:
- Freechat/Dockerfile
script: script:
- sleep 10 & - cd Freechat/
- a=$! - echo $VERSION
- echo $a - docker build -t freechat .
- setsid echo this testvar value is $TEST_VAR - docker tag freechat "$USER/freechat:$VERSION"
- docker push "$USER/freechat:$VERSION"
build-freechat-pipeline:
stage: default
only:
refs:
- master
changes:
- freechat-pipeline/entrypoint.sh
- freechat-pipeline/Dockerfile
script:
- cd freechat-pipeline/
- docker build -t freechat-pipeline .
- docker tag freechat-pipeline "$USER/freechat-pipeline:latest"
- docker push "$USER/freechat-pipeline:latest"