]> git.immae.eu Git - github/fretlink/ansible-clever.git/blame - .travis.yml
Extract environment building tasks from the JSON template
[github/fretlink/ansible-clever.git] / .travis.yml
CommitLineData
8692bc27 1---
8692bc27 2sudo: false
df5fbcce
PB
3language: nix
4nix: 2.2.1
5env:
6 - NIX_PATH=nixpkgs=channel:nixos-19.09
8692bc27 7
8692bc27 8install:
df5fbcce 9 - nix-env -iA pkgs.python37Packages.ansible-lint pkgs.python37Packages.ansible pkgs.shellcheck -f '<nixpkgs>'
2acb3d4f 10 - nix-env -if ./dhall-1.26.1.nix
8692bc27
GD
11
12 # Check ansible version
13 - ansible --version
14
f03052d5
FM
15 # Alias role name to mimic actual Galaxy deployment
16 - ln -s ansible-clever ../clever
17
8692bc27
GD
18 # Create ansible.cfg with correct roles_path
19 - printf '[defaults]\nroles_path=../' >ansible.cfg
20
21script:
22 # Basic role syntax check
23 - ansible-playbook tests/test.yml -i tests/inventory --syntax-check
7485b189 24 - ansible-lint .
2867b6f2 25 - shellcheck **/*.sh
8b59c20a 26 - scripts/dhall_check.sh
c99eb178
PB
27 # Run integration test
28 - mkdir -p ~/.local/bin
29 - cp tests/fake.sh ~/.local/bin/clever
30 - cp tests/fake.sh ~/.local/bin/git
31 - ansible-playbook tests/test.yml -i tests/inventory
8692bc27
GD
32
33notifications:
910f387d 34 slack: fretlink:pTIylIN7zkwRFuL3aHERmsbB
c99eb178 35 webhooks: https://galaxy.ansible.com/api/v1/notifications/