mirror of
https://github.com/h44z/wg-portal.git
synced 2025-12-18 12:16:18 +00:00
wip: docker and travis
This commit is contained in:
32
.travis.yml
Normal file
32
.travis.yml
Normal file
@@ -0,0 +1,32 @@
|
||||
# make use of vm's
|
||||
sudo: 'required'
|
||||
|
||||
# have the docker service set up (we'll
|
||||
# update it later)
|
||||
services:
|
||||
- docker
|
||||
|
||||
# prepare the machine before any code
|
||||
# installation scripts
|
||||
before_install:
|
||||
- ./.travis/main.sh
|
||||
|
||||
|
||||
script:
|
||||
- make test
|
||||
- make docker-image
|
||||
|
||||
|
||||
# only execute the following instructions in
|
||||
# the case of a success (failing at this point
|
||||
# won't mark the build as a failure).
|
||||
# To have `DOCKER_USERNAME` and `DOCKER_PASSWORD`
|
||||
# filled you need to either use `travis`' cli
|
||||
# and then `travis set ..` or go to the travis
|
||||
# page of your repository and then change the
|
||||
# environment in the settings panel.
|
||||
after_success:
|
||||
- if [[ "$TRAVIS_BRANCH" == "master" ]]; then
|
||||
docker login -u $DOCKER_USERNAME -p $DOCKER_PASSWORD ;
|
||||
make docker-push ;
|
||||
fi
|
||||
Reference in New Issue
Block a user