2019-05-02 17:28:20 +02:00
|
|
|
dist: xenial
|
|
|
|
language: bash
|
2020-01-24 10:43:25 +01:00
|
|
|
services:
|
2019-05-02 17:28:20 +02:00
|
|
|
- docker
|
2019-11-11 22:03:20 +01:00
|
|
|
|
2019-05-02 17:28:20 +02:00
|
|
|
addons:
|
|
|
|
apt:
|
|
|
|
packages:
|
|
|
|
- jq
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
include:
|
|
|
|
- stage: test
|
|
|
|
script:
|
2019-05-16 19:23:07 +02:00
|
|
|
- git ls-files --exclude='*Dockerfile' --ignored | xargs --max-lines=1 -I{} sh -c 'docker run --rm -i -v ${PWD}/.hadolint.yaml:/.hadolint.yaml hadolint/hadolint < "$1"' -- {}
|
2019-05-02 17:28:20 +02:00
|
|
|
- bash -c 'shopt -s globstar; shellcheck **/*.sh'
|
2019-11-11 22:03:20 +01:00
|
|
|
|
2019-05-02 17:28:20 +02:00
|
|
|
- &build
|
2019-11-20 22:57:13 +01:00
|
|
|
stage: Build & update Docker HUB description
|
2020-01-24 10:37:42 +01:00
|
|
|
env: VERSION_SHORT=0.18 EXTRA_TAG=latest
|
2019-05-02 17:28:20 +02:00
|
|
|
script:
|
2019-05-16 19:23:07 +02:00
|
|
|
- ./build.sh $VERSION_SHORT
|
2020-01-24 10:37:42 +01:00
|
|
|
- <<: *build
|
|
|
|
env: VERSION_SHORT=0.17 EXTRA_TAG=stable
|
2019-05-02 17:28:20 +02:00
|
|
|
- <<: *build
|
2019-10-18 10:53:16 +02:00
|
|
|
env: VERSION_SHORT=0.16
|
2019-05-02 17:28:20 +02:00
|
|
|
- <<: *build
|
2019-05-16 19:23:07 +02:00
|
|
|
env: VERSION_SHORT=0.15
|
2019-05-02 17:28:20 +02:00
|
|
|
- <<: *build
|
2019-05-16 19:23:07 +02:00
|
|
|
env: VERSION_SHORT=0.14
|
2019-11-25 01:48:55 +01:00
|
|
|
- <<: *build
|
2020-01-24 10:43:25 +01:00
|
|
|
if: branch = master AND type != pull_request
|
2019-11-25 01:51:05 +01:00
|
|
|
env:
|
2019-11-20 22:57:13 +01:00
|
|
|
script: docker run -v $PWD:/workspace -e DOCKERHUB_USERNAME=$DOCKER_USERNAME -e DOCKERHUB_PASSWORD=$DOCKER_PASSWORD -e DOCKERHUB_REPOSITORY='factoriotools/factorio' -e README_FILEPATH='/workspace/README.md' peterevans/dockerhub-description:2.1.0
|