nusenu / ansible-relayor

An Ansible Role for Tor Relay Operators
GNU General Public License v3.0
248 stars 43 forks source link

Consider enabling diff in ansible_push provisioner #199

Closed Lirt closed 5 years ago

Lirt commented 5 years ago

I think that it would be nice to enable diff: true in ansible_push provisioner configuration.

This will make kitchen tests output file differences if there are any.

This will help us see what changes happened to files, if we are changing templates or different configurations and it will make us clearly see any errors, mistakes or typos during testing.

Example:

TASK [ansible-relayor : Create links to the service files (OpenBSD)] **********************************************************************************************************************************************
--- before
+++ after
@@ -1,4 +1,4 @@
 {
     "path": "/etc/rc.d/tor10_0_2_15_9000",
-    "state": "absent"
+    "state": "link"
 }

changed: [guard-openbsd] => (item=[{u'ipv4': u'10.0.2.15', u'ipv6': u''}, {u'orport': 9000, u'dirport': 9001}])
--- before
+++ after
@@ -1,4 +1,4 @@
 {
     "path": "/etc/rc.d/tor10_0_2_15_9100",
-    "state": "absent"
+    "state": "link"
 }
nusenu commented 5 years ago

very useful, thanks!

Lirt commented 5 years ago

PR in https://github.com/nusenu/ansible-relayor/pull/201

nusenu commented 5 years ago

thanks, merged.