create snmp dir and configuration
This commit is contained in:
@@ -15,6 +15,19 @@
|
|||||||
validate: "visudo -cf %s"
|
validate: "visudo -cf %s"
|
||||||
when: ansible_distribution in ["Debian", "Ubuntu"]
|
when: ansible_distribution in ["Debian", "Ubuntu"]
|
||||||
|
|
||||||
|
- name: server | snmpd | create /etc/snmp
|
||||||
|
file:
|
||||||
|
path: "/etc/snmp"
|
||||||
|
state: directory
|
||||||
|
owner: "root"
|
||||||
|
group: "root"
|
||||||
|
- name: server | snmpd | create /etc/snmp/snmpd.conf
|
||||||
|
file:
|
||||||
|
path: "/etc/snmp/snmpd.conf"
|
||||||
|
state: present
|
||||||
|
owner: "root"
|
||||||
|
group: "root"
|
||||||
|
|
||||||
- name: server | snmpd | insert anchors to snmpd.conf
|
- name: server | snmpd | insert anchors to snmpd.conf
|
||||||
blockinfile:
|
blockinfile:
|
||||||
path: "{{ snmpd_conf }}"
|
path: "{{ snmpd_conf }}"
|
||||||
|
|||||||
Reference in New Issue
Block a user