Closed janondrusek closed 6 years ago
I'm impressed that you don't have other issues before this role in the common playbook, unless you use the role directly. Yes, I suppose that a when: ansible_distribution in [ 'Debian', 'Ubuntu' ]
for this task should suffice. I'll add this in my rewrite PR. NB, would you like to test the new changes on CentOS to see if any other issues show up?
Yes, that worked:
diff --git a/tasks/main.yml b/tasks/main.yml
index 561f072..d5bd27a 100644
--- a/tasks/main.yml
+++ b/tasks/main.yml
@@ -6,6 +6,7 @@
question: 'ferm/enable'
vtype: 'boolean'
value: '{{ "yes" if ferm__enabled|bool else "no" }}'
+ when: ansible_distribution in [ 'Debian', 'Ubuntu' ]
- name: Ensure ferm is installed
package:
Usually the only blockers are apt
related tasks, that do not have an optional when
clause. E.g. https://github.com/debops/ansible-bootstrap/issues/40
has no option to be skipped, except for entirely disabling the role. I am using debops on CentOS and direct use of debconf would require a custom fork.
Would it be possible to add a skip option for it?
Thanks