X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=.travis.yml;h=8dee9bda29cda19cc5da5f8743dd541243ff278f;hb=e8dd12d4d9248db0df8ca17969924083e588e961;hp=812d0fe88059d5eec71a3a3bb93c657eb549a2ea;hpb=208d503983ba44c64f92c20e8d062905a2ac47f5;p=github%2Ffretlink%2Fansible-kong-app.git diff --git a/.travis.yml b/.travis.yml index 812d0fe..8dee9bd 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,32 +1,40 @@ --- -language: python -python: "2.7" +language: nix +nix: 2.3.6 +env: + - CUSTOM_NIX_PATH=nixpkgs=channel:nixos-20.09 -# Use the new container infrastructure -sudo: false - -# Install ansible -addons: - apt: - packages: - - python-pip +# Travis nix integration will install nix AFTER the environment variables are set +# and the nix installer will overide NIX_PATH variable thus we need to re-export it +before_install: + - export NIX_PATH="$CUSTOM_NIX_PATH" install: - # Install ansible - - pip install ansible - - pip install ansible-lint + # Install dependencies + - nix-env -i -f ./default.nix # Check ansible version - ansible --version + - ansible-lint --version # Create ansible.cfg with correct roles_path - printf '[defaults]\nroles_path=../' >ansible.cfg + # Basic webserver to fake a Kong + - | + ./tests/kong.py& script: # Basic role syntax check - ansible-playbook tests/test.yml -i tests/inventory --syntax-check - ansible-lint . - - ansible-playbook tests/test.yml -i tests/inventory -C -D + - ansible-playbook tests/test.yml -i tests/inventory -D + - scripts/dhall_check.sh notifications: webhooks: https://galaxy.ansible.com/api/v1/notifications/ + slack: + rooms: + - secure: cNAlklFQhu3CRi4Vp+U1veIbSvpAvqVNa0I9knRe8r5Xz6jczuxtKYVnP5m8q1iY38zx3ekjFn+2VdFQgr0twqUYGFMr+YbOWfLdcWxmA6BI29/6kdpoX0uihMEOl5uAyVm7hOiU/DfPxsbQMJeEFY4r/eYM+wErAtFC0c8bWt4oskjJJQPmr7DB/fOaefKkGoVjKElO6goVRWy2fHkGdldvV5EcQPdNW82ZY0w27e7fWm9Yv0D/Jr7Qu9i00UCdT3LyJ05cKVdaxxQOx0xjh+h0V4lN/CRfEBk8LQW3Ror+vnFgQHFkxSzY/MOASBvxZPMj/PFPCP1AwYlxz46dDHnaN2+tNc4Pdj/2qqZPjDW03KqjLRNY3fyfvjX2Yz+2da2hiF7WZReRcFZp0KGxLGTrpFFQ+JOEbYDvK0p4ZswNkDwnI9iYJoI7wntL614y4wIiCRxDR1/aTOGLr+M05WSdBhocL0x8IGVZNKa2yRpcgwlM35QMYSd7QFQmgB6MCIlqHxa1zGg124iepjL1SXp49SwQBI9k1mO4N7z469ZVyEdqydBMMQiiay2mP+fEBAM9gOboV4rMkCSQoMMED+MyiwGRioFor34/t7MQFM18ZoUemQAYRK7iAyCO7JnQOkilAVi+ZIfpiUrrBhBpz5JopeaFEIp4yAuJRyvWD0c= + on_success: change # default: always + on_failure: always # default: always + on_pull_requests: false