common: unify string escaping style
This commit is contained in:
parent
3c56af2906
commit
931d97359e
@ -28,10 +28,10 @@
|
|||||||
copy: src={{ item.src }} dest={{ item.dest }}
|
copy: src={{ item.src }} dest={{ item.dest }}
|
||||||
diff: no
|
diff: no
|
||||||
with_items:
|
with_items:
|
||||||
- { src: '.zshrc', dest: '/root/.zshrc' }
|
- { src: ".zshrc", dest: "/root/.zshrc" }
|
||||||
- { src: '.zshrc.local', dest: '/root/.zshrc.local' }
|
- { src: ".zshrc.local", dest: "/root/.zshrc.local" }
|
||||||
- { src: 'motd', dest: '/etc/motd' }
|
- { src: "motd", dest: "/etc/motd" }
|
||||||
- { src: 'vimrc.local', dest: '/etc/vim/vimrc.local' }
|
- { src: "vimrc.local", dest: "/etc/vim/vimrc.local" }
|
||||||
|
|
||||||
- name: Set shell for root user
|
- name: Set shell for root user
|
||||||
user: name=root shell=/bin/zsh
|
user: name=root shell=/bin/zsh
|
||||||
@ -52,8 +52,8 @@
|
|||||||
- name: Prevent normal users from running su
|
- name: Prevent normal users from running su
|
||||||
lineinfile:
|
lineinfile:
|
||||||
path: /etc/pam.d/su
|
path: /etc/pam.d/su
|
||||||
regexp: '^.*auth\s+required\s+pam_wheel.so$'
|
regexp: "^.*auth\\s+required\\s+pam_wheel.so$"
|
||||||
line: 'auth required pam_wheel.so'
|
line: "auth required pam_wheel.so"
|
||||||
|
|
||||||
- name: Configure journald retention
|
- name: Configure journald retention
|
||||||
lineinfile:
|
lineinfile:
|
||||||
@ -88,14 +88,14 @@
|
|||||||
set_fact:
|
set_fact:
|
||||||
logrotateconfigpaths: "{{ alllogrotateconfigpaths | difference(logrotate_excludes) }}"
|
logrotateconfigpaths: "{{ alllogrotateconfigpaths | difference(logrotate_excludes) }}"
|
||||||
|
|
||||||
- name: 'Set logrotate.d/* to daily'
|
- name: "Set logrotate.d/* to daily"
|
||||||
replace:
|
replace:
|
||||||
path: "{{ item }}"
|
path: "{{ item }}"
|
||||||
regexp: "(?:weekly|monthly)"
|
regexp: "(?:weekly|monthly)"
|
||||||
replace: "daily"
|
replace: "daily"
|
||||||
loop: "{{ logrotateconfigpaths }}"
|
loop: "{{ logrotateconfigpaths }}"
|
||||||
|
|
||||||
- name: 'Set /etc/logrotate.d/* rotation to 7'
|
- name: "Set /etc/logrotate.d/* rotation to 7"
|
||||||
replace:
|
replace:
|
||||||
path: "{{ item }}"
|
path: "{{ item }}"
|
||||||
regexp: "rotate [0-9]+"
|
regexp: "rotate [0-9]+"
|
||||||
|
@ -15,10 +15,10 @@
|
|||||||
copy: src={{ item.src }} dest={{ item.dest }}
|
copy: src={{ item.src }} dest={{ item.dest }}
|
||||||
diff: no
|
diff: no
|
||||||
with_items:
|
with_items:
|
||||||
- { src: '.zshrc', dest: '/root/.zshrc' }
|
- { src: ".zshrc", dest: "/root/.zshrc" }
|
||||||
- { src: '.zshrc.local', dest: '/root/.zshrc.local' }
|
- { src: ".zshrc.local", dest: "/root/.zshrc.local" }
|
||||||
- { src: 'motd', dest: '/etc/motd' }
|
- { src: "motd", dest: "/etc/motd" }
|
||||||
- { src: 'vimrc.local', dest: '/etc/vim/vimrc.local' }
|
- { src: "vimrc.local", dest: "/etc/vim/vimrc.local" }
|
||||||
|
|
||||||
- name: Set shell for root user
|
- name: Set shell for root user
|
||||||
user: name=root shell=/bin/zsh
|
user: name=root shell=/bin/zsh
|
||||||
|
@ -2,20 +2,20 @@
|
|||||||
|
|
||||||
- name: Cleanup
|
- name: Cleanup
|
||||||
apt: autoclean=yes
|
apt: autoclean=yes
|
||||||
when: ansible_os_family == 'Debian'
|
when: ansible_os_family == "Debian"
|
||||||
|
|
||||||
- name: Gather package facts
|
- name: Gather package facts
|
||||||
package_facts:
|
package_facts:
|
||||||
manager: apt
|
manager: apt
|
||||||
when: ansible_os_family == 'Debian'
|
when: ansible_os_family == "Debian"
|
||||||
|
|
||||||
- name: Proxmox
|
- name: Proxmox
|
||||||
include: Proxmox.yml
|
include: Proxmox.yml
|
||||||
when: ansible_os_family == 'Debian' and 'pve-manager' in ansible_facts.packages
|
when: ansible_os_family == "Debian" and "pve-manager" in ansible_facts.packages
|
||||||
|
|
||||||
- name: Debian
|
- name: Debian
|
||||||
include: Debian.yml
|
include: Debian.yml
|
||||||
when: ansible_os_family == 'Debian' and 'pve-manager' not in ansible_facts.packages
|
when: ansible_os_family == "Debian" and "pve-manager" not in ansible_facts.packages
|
||||||
|
|
||||||
- name: Setup chrony
|
- name: Setup chrony
|
||||||
include: chrony.yml
|
include: chrony.yml
|
||||||
|
Loading…
Reference in New Issue
Block a user