disable firewall in bootstrap-server
Closes-Bug: #1638762 Change-Id: I23565f72166088444a49269ff9e406a3ab7a40d4
This commit is contained in:
parent
9779778a1e
commit
d7ed014277
@ -4,6 +4,28 @@
|
||||
become: True
|
||||
when: ansible_os_family == 'Debian'
|
||||
|
||||
- name: Set firewall default policy
|
||||
ufw: state=disabled policy=allow
|
||||
when: ansible_os_family == 'Debian'
|
||||
|
||||
- name: Check if firewalld is installed
|
||||
command: rpm -q firewalld
|
||||
register: firewalld_check
|
||||
failed_when: firewalld_check.rc > 1
|
||||
when: ansible_os_family == 'RedHat'
|
||||
|
||||
- name: Disable firewalld
|
||||
become: True
|
||||
service:
|
||||
name: "{{ item }}"
|
||||
enabled: false
|
||||
state: stopped
|
||||
with_items:
|
||||
- firewalld
|
||||
when:
|
||||
- ansible_os_family == 'RedHat'
|
||||
- firewalld_check.rc == 0
|
||||
|
||||
- name: Install apt packages
|
||||
package: name={{item}} state=present
|
||||
become: True
|
||||
|
Loading…
x
Reference in New Issue
Block a user