telegraf: Adjust directory permissions

This patch reduces the permissions on the install directory to just the root user and also fixes the ansible-lint issue by specifying the `mode`.
This commit is contained in:
saibotk 2020-09-26 21:39:38 +02:00
parent 309aa18d61
commit c8030de88b
No known key found for this signature in database
GPG key ID: A3299C587D5DF523

View file

@ -30,14 +30,19 @@
file: file:
path: "{{ item }}" path: "{{ item }}"
state: directory state: directory
mode: '0700'
owner: 'root'
group: 'root'
with_items: with_items:
- "{{ telegraf_install_location }}" - "{{ telegraf_install_location }}"
become: true become: true
- name: Create data directory - name: Create config directory
file: file:
path: "{{ item }}" path: "{{ item }}"
mode: "0700" mode: '0700'
owner: 'root'
group: 'root'
state: directory state: directory
setype: "container_file_t" setype: "container_file_t"
with_items: with_items: