Refs #8025 Rol debian-base. All task - Refactor from octal permissions to plain text

This commit is contained in:
Xavi Lleó 2024-10-10 16:12:29 +02:00
parent 3e7771ba4c
commit 588db894a1
10 changed files with 12 additions and 13 deletions

View File

@ -12,7 +12,7 @@
dest: /etc/bacula/bacula-fd.conf dest: /etc/bacula/bacula-fd.conf
owner: root owner: root
group: bacula group: bacula
mode: '0640' mode: u=rw,g=r,o=
backup: true backup: true
- name: Restart Bacula FD service - name: Restart Bacula FD service
service: service:

View File

@ -8,5 +8,5 @@
dest: /etc/fail2ban/jail.local dest: /etc/fail2ban/jail.local
owner: root owner: root
group: root group: root
mode: '0644' mode: u=rw,g=r,o=r
notify: restart-fail2ban notify: restart-fail2ban

View File

@ -2,6 +2,6 @@
copy: copy:
src: motd src: motd
dest: /etc/update-motd.d/90-vn dest: /etc/update-motd.d/90-vn
mode: '755' mode: u=rwx,g=rx,o=rx
owner: root owner: root
group: root group: root

View File

@ -2,6 +2,6 @@
copy: copy:
src: profile.sh src: profile.sh
dest: /etc/profile.d/vn.sh dest: /etc/profile.d/vn.sh
mode: '644' mode: u=rw,g=r,o=r
owner: root owner: root
group: root group: root

View File

@ -17,7 +17,7 @@
dc_hide_mailname='true' dc_hide_mailname='true'
state: present state: present
create: yes create: yes
mode: '0644' mode: u=rw,g=r,o=r
notify: update exim configuration notify: update exim configuration
register: exim_config register: exim_config
- name: Force execution of handlers immediately - name: Force execution of handlers immediately

View File

@ -17,6 +17,6 @@
dest: /etc/resolv.conf dest: /etc/resolv.conf
owner: root owner: root
group: root group: root
mode: '0644' mode: u=rw,g=r,o=r
backup: true backup: true
when: not resolv_conf.stat.exists or not dns_configured when: not resolv_conf.stat.exists or not dns_configured

View File

@ -6,16 +6,15 @@
register: new_pair register: new_pair
- name: Configure sshd_config settings - name: Configure sshd_config settings
copy: copy:
dest: /etc/ssh/sshd_config.d/custom.conf dest: /etc/ssh/sshd_config.d/vn-custom.conf
content: | content: |
# Do not edit this file! Ansible will overwrite it. # Do not edit this file! Ansible will overwrite it.
ListenAddress 0.0.0.0 ListenAddress 0.0.0.0
SyslogFacility AUTH SyslogFacility AUTH
permitRootLogin yes
owner: root owner: root
group: root group: root
mode: '0644' mode: u=rw,g=r,o=r
- name: Delete old host SSH keys - name: Delete old host SSH keys
file: file:
path: "{{ item }}" path: "{{ item }}"

View File

@ -4,7 +4,7 @@
state: directory state: directory
owner: root owner: root
group: root group: root
mode: '0755' mode: u=rwx,g=rx,o=rx
- name: Configure NTP settings in /etc/systemd/timesyncd.conf.d/vn-ntp.conf - name: Configure NTP settings in /etc/systemd/timesyncd.conf.d/vn-ntp.conf
copy: copy:
dest: /etc/systemd/timesyncd.conf.d/vn-ntp.conf dest: /etc/systemd/timesyncd.conf.d/vn-ntp.conf
@ -14,7 +14,7 @@
FallbackNTP={{ time_server_spain }} FallbackNTP={{ time_server_spain }}
owner: root owner: root
group: root group: root
mode: '0644' mode: u=rw,g=r,o=r
notify: restart systemd-timesyncd notify: restart systemd-timesyncd
- name: Ensure systemd-timesyncd service is enabled and started - name: Ensure systemd-timesyncd service is enabled and started
service: service:

View File

@ -6,6 +6,6 @@
copy: copy:
src: vimrc.local src: vimrc.local
dest: /etc/vim/ dest: /etc/vim/
mode: '644' mode: u=rw,g=r,o=r
owner: root owner: root
group: root group: root

View File

@ -2,7 +2,7 @@
get_url: get_url:
url: "{{ vn_host.url }}/{{ vn_host.package }}" url: "{{ vn_host.url }}/{{ vn_host.package }}"
dest: "/tmp/{{ vn_host.package }}" dest: "/tmp/{{ vn_host.package }}"
mode: '0644' mode: u=rw,g=r,o=r
- name: Install package - name: Install package
apt: apt:
deb: "/tmp/{{ vn_host.package }}" deb: "/tmp/{{ vn_host.package }}"