Skip to content

Instantly share code, notes, and snippets.

@meatballhat
Last active December 27, 2015 18:48
Show Gist options
  • Save meatballhat/7372053 to your computer and use it in GitHub Desktop.
Save meatballhat/7372053 to your computer and use it in GitHub Desktop.
example .travis.yml for use with docker-build-server and docker-build-worker

Example .travis.yml for docker-build-server integration

The docker_build section is optional, but omitting it will result in the container being built and then not pushed, which is probably not what you want. The tag argument should probably be called repo_tag since it's both the docker repo and tag in the format expected by commands like docker run.

The docker_build.notify_hipchat key being set to true will result in docker-build-worker using the value at notifications.hipchat.rooms[0]. It's worth noting that docker_build.notify_campfire is also supported. Alternatively, docker_build.notify_(hipchat|campfire) may be set to its own value, e.g. abcdef123456@Some Other Room.

Linkies

---
language: ruby
# ... more stuff ...
docker_build:
auto_push: true
tag: quay.io/modcloth/name-of-project:$TRAVIS_SHORT_COMMIT
notify_hipchat: true
notifications:
webhooks:
urls:
- https://docker-build-server.example.com/travis-webhook
on_success: always
on_failure: never
hipchat:
rooms:
- abcdef123456@Name Of Room Go Here
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment