From 7b5e905a20fc52d4ea33c750d4b8caa7f3aa353f Mon Sep 17 00:00:00 2001 From: Matt Willsher Date: Thu, 23 May 2019 20:34:28 +0100 Subject: [PATCH] Use become not sudo --- .travis.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.travis.yml b/.travis.yml index 3a85aed..1e98a38 100644 --- a/.travis.yml +++ b/.travis.yml @@ -25,11 +25,11 @@ script: - "ANSIBLE_FORCE_COLOR=1 ansible-playbook -i tests/inventory tests/test.yml --syntax-check" # Run the role - - "ANSIBLE_FORCE_COLOR=1 ansible-playbook -i tests/inventory tests/test.yml --connection=local --sudo -v" + - "ANSIBLE_FORCE_COLOR=1 ansible-playbook -i tests/inventory tests/test.yml --connection=local --become -v" # Run the role/playbook again, checking to make sure it's idempotent. - > - ansible-playbook -i tests/inventory tests/test.yml --connection=local --sudo - | grep -q 'changed=0.*failed=0' + ansible-playbook -i tests/inventory tests/test.yml --connection=local --become | grep -q 'changed=0.*failed=0' && (echo 'Idempotence test: pass' && exit 0) || (echo 'Idempotence test: fail' && exit 1) +