2014-08-04 04:27:16 +02:00
|
|
|
---
|
2016-09-25 22:50:13 +02:00
|
|
|
services: docker
|
2014-08-04 04:27:16 +02:00
|
|
|
|
|
|
|
env:
|
2016-09-25 22:50:13 +02:00
|
|
|
- distro: centos7
|
|
|
|
- distro: ubuntu1604
|
|
|
|
- distro: ubuntu1404
|
|
|
|
- distro: ubuntu1204
|
2014-08-04 04:27:16 +02:00
|
|
|
|
|
|
|
script:
|
2017-03-25 20:19:08 +01:00
|
|
|
# Configure test script so we can run extra tests after playbook is run.
|
|
|
|
- export container_id=$(date +%s)
|
|
|
|
- export cleanup=false
|
|
|
|
|
2017-04-02 06:34:07 +02:00
|
|
|
# Download test shim.
|
|
|
|
- wget -O ${PWD}/tests/test.sh https://gist.githubusercontent.com/geerlingguy/73ef1e5ee45d8694570f334be385e181/raw/
|
|
|
|
- chmod +x ${PWD}/tests/test.sh
|
2014-08-04 04:27:16 +02:00
|
|
|
|
2017-04-02 06:34:07 +02:00
|
|
|
# Run tests.
|
|
|
|
- ${PWD}/tests/test.sh
|
2016-09-14 05:31:30 +02:00
|
|
|
|
2017-03-25 20:19:08 +01:00
|
|
|
# Setup test site.
|
|
|
|
- 'docker exec ${container_id} mkdir -p /var/www/test'
|
|
|
|
- 'docker exec ${container_id} bash -c "echo Success >| /var/www/test/index.html"'
|
|
|
|
|
|
|
|
# Make sure virtualhost exists.
|
|
|
|
- 'docker exec --tty ${container_id} env TERM=xterm curl http://test.dev/ | grep "Success"'
|
|
|
|
|
2016-02-29 21:58:50 +01:00
|
|
|
notifications:
|
|
|
|
webhooks: https://galaxy.ansible.com/api/v1/notifications/
|