jdauphant / ansible-role-nginx

Ansible role to install and manage nginx configuration
655 stars 302 forks source link

remove default.conf in ubuntu16 #176

Closed adamyala closed 7 years ago

adamyala commented 7 years ago

On ubuntu16, default is called default.conf. This PR adds default.conf to the list of default files to remove in the task Disable the default site

adamyala commented 7 years ago

The error in travis is:

The command "ansible-playbook -i inventory --connection=local --sudo -vvvv test/test.yml -u root -e "role_name=ansible-role-nginx" -e "hosts_group=localhost" | grep -q 'changed=0.*failed=0' && (echo 'Idempotence test: pass' && exit 0) || (echo 'Idempotence test: fail' && exit 1)

Could I have some guidance as to what that means? I can go back in and fix it up.

jdauphant commented 7 years ago

@adamyala It's because the role create a "default.conf" by default: https://github.com/jdauphant/ansible-role-nginx/blob/master/defaults/main.yml#L36 By removing this, the role isn't "Idempotence" anymore.

2 solutions:

adamyala commented 7 years ago

I decided to just add:

nginx_remove_sites: [default]

after the nginx_sites portion. Thank you for clarifying and thank you got continuing to maintain this role!

jdauphant commented 7 years ago

You're welcome :)