diff --git a/resources/playbook/roles/bibigrid/tasks/000-add-ip-routes.yaml b/resources/playbook/roles/bibigrid/tasks/000-add-ip-routes.yaml index e193ccc6..732ed9ce 100644 --- a/resources/playbook/roles/bibigrid/tasks/000-add-ip-routes.yaml +++ b/resources/playbook/roles/bibigrid/tasks/000-add-ip-routes.yaml @@ -15,7 +15,7 @@ dest: "{{ item.path }}.disabled" owner: root group: root - mode: 0644 + mode: 0o644 remote_src: true with_items: "{{ collected_files.files }}" - name: Remove collected files @@ -30,7 +30,7 @@ line: "network: {config: disabled}" owner: root group: root - mode: 0644 + mode: 0o644 create: true - name: Generate location specific worker userdata @@ -39,7 +39,7 @@ dest: "/etc/systemd/network/bibigrid_ens3.network" owner: root group: systemd-network - mode: 0640 + mode: 0o640 become: true notify: - systemd-networkd restart @@ -50,7 +50,7 @@ dest: "/etc/systemd/network/bibigrid_ens3.link" owner: root group: systemd-network - mode: 0640 + mode: 0o640 become: true notify: - systemd-networkd restart diff --git a/resources/playbook/roles/bibigrid/tasks/001-apt.yaml b/resources/playbook/roles/bibigrid/tasks/001-apt.yaml index 0ca1c17b..7fdf90dc 100644 --- a/resources/playbook/roles/bibigrid/tasks/001-apt.yaml +++ b/resources/playbook/roles/bibigrid/tasks/001-apt.yaml @@ -8,7 +8,7 @@ dest: /etc/apt/apt.conf.d/20auto-upgrades owner: root group: root - mode: 0644 + mode: 0o644 - name: Wait for cloud-init / user-data to finish command: cloud-init status --wait diff --git a/resources/playbook/roles/bibigrid/tasks/002-wireguard-vpn.yaml b/resources/playbook/roles/bibigrid/tasks/002-wireguard-vpn.yaml index d70f10a5..cb293246 100644 --- a/resources/playbook/roles/bibigrid/tasks/002-wireguard-vpn.yaml +++ b/resources/playbook/roles/bibigrid/tasks/002-wireguard-vpn.yaml @@ -9,7 +9,7 @@ dest: /etc/systemd/network/wg0.netdev owner: root group: systemd-network - mode: 0640 + mode: 0o640 become: true notify: - systemd-networkd restart @@ -20,7 +20,7 @@ dest: /etc/systemd/network/wg0.network owner: root group: systemd-network - mode: 0640 + mode: 0o640 become: true notify: systemd-networkd restart diff --git a/resources/playbook/roles/bibigrid/tasks/011-zabbix-agent.yaml b/resources/playbook/roles/bibigrid/tasks/011-zabbix-agent.yaml index 9a658689..8249f68f 100644 --- a/resources/playbook/roles/bibigrid/tasks/011-zabbix-agent.yaml +++ b/resources/playbook/roles/bibigrid/tasks/011-zabbix-agent.yaml @@ -11,7 +11,7 @@ file: path: /etc/zabbix/zabbix_agentd.d/ state: directory - mode: 0755 + mode: 0o755 - name: Create zabbix_agent log directory file: @@ -19,7 +19,7 @@ state: directory owner: zabbix group: zabbix - mode: 0755 + mode: 0o755 - name: Adjust zabbix agent configuration template: diff --git a/resources/playbook/roles/bibigrid/tasks/011-zabbix-server.yaml b/resources/playbook/roles/bibigrid/tasks/011-zabbix-server.yaml index df2b5def..461b0519 100644 --- a/resources/playbook/roles/bibigrid/tasks/011-zabbix-server.yaml +++ b/resources/playbook/roles/bibigrid/tasks/011-zabbix-server.yaml @@ -69,7 +69,7 @@ template: src: zabbix/zabbix_server.conf.j2 dest: /etc/zabbix/zabbix_server.conf - mode: 0644 + mode: 0o644 notify: zabbix-server - name: Start and Enable zabbix-server diff --git a/resources/playbook/roles/bibigrid/tasks/020-disk-server-automount.yaml b/resources/playbook/roles/bibigrid/tasks/020-disk-server-automount.yaml index 8e4b5f49..a33ffd91 100644 --- a/resources/playbook/roles/bibigrid/tasks/020-disk-server-automount.yaml +++ b/resources/playbook/roles/bibigrid/tasks/020-disk-server-automount.yaml @@ -21,7 +21,7 @@ file: path: "/vol/{{ item.mount_point }}" state: directory - mode: '0755' + mode: 0o755 owner: root group: '{{ ansible_distribution | lower }}' diff --git a/resources/playbook/roles/bibigrid/tasks/020-disk-worker.yaml b/resources/playbook/roles/bibigrid/tasks/020-disk-worker.yaml index 4acf3b56..f558063b 100644 --- a/resources/playbook/roles/bibigrid/tasks/020-disk-worker.yaml +++ b/resources/playbook/roles/bibigrid/tasks/020-disk-worker.yaml @@ -11,4 +11,4 @@ file: path: /vol/scratch state: directory - mode: 0777 + mode: 0o777 diff --git a/resources/playbook/roles/bibigrid/tasks/020-disk.yaml b/resources/playbook/roles/bibigrid/tasks/020-disk.yaml index 08b4b980..92338663 100644 --- a/resources/playbook/roles/bibigrid/tasks/020-disk.yaml +++ b/resources/playbook/roles/bibigrid/tasks/020-disk.yaml @@ -4,7 +4,7 @@ state: directory owner: root group: '{{ ansible_distribution | lower }}' - mode: 0775 + mode: 0o775 - name: Create /vol/ directory with rights 0775 owned by root file: @@ -12,13 +12,13 @@ state: directory owner: root group: '{{ ansible_distribution | lower }}' - mode: 0775 + mode: 0o775 - name: Create /vol/spool/ directory with rights 0777 file: path: /vol/spool/ state: directory - mode: 0777 + mode: 0o777 - name: Change rights of /opt directory to 0775 and set group to ansible_distribution file: @@ -26,7 +26,7 @@ state: directory owner: root group: '{{ ansible_distribution | lower }}' - mode: 0775 + mode: 0o775 - name: Create link in '{{ ansible_distribution | lower }}' home file: diff --git a/resources/playbook/roles/bibigrid/tasks/025-nfs-server.yaml b/resources/playbook/roles/bibigrid/tasks/025-nfs-server.yaml index c7030971..cb91d8f3 100644 --- a/resources/playbook/roles/bibigrid/tasks/025-nfs-server.yaml +++ b/resources/playbook/roles/bibigrid/tasks/025-nfs-server.yaml @@ -9,7 +9,7 @@ state: directory owner: root group: root - mode: 0777 + mode: 0o777 with_items: - "{{ nfs_mounts }}" diff --git a/resources/playbook/roles/bibigrid/tasks/025-nfs-worker.yaml b/resources/playbook/roles/bibigrid/tasks/025-nfs-worker.yaml index 71217302..21d2c264 100644 --- a/resources/playbook/roles/bibigrid/tasks/025-nfs-worker.yaml +++ b/resources/playbook/roles/bibigrid/tasks/025-nfs-worker.yaml @@ -16,7 +16,7 @@ state: directory owner: root group: root - mode: 0777 + mode: 0o777 with_items: - "{{ nfs_mounts }}" diff --git a/resources/playbook/roles/bibigrid/tasks/030-docker.yaml b/resources/playbook/roles/bibigrid/tasks/030-docker.yaml index 07830b2b..8a681a81 100644 --- a/resources/playbook/roles/bibigrid/tasks/030-docker.yaml +++ b/resources/playbook/roles/bibigrid/tasks/030-docker.yaml @@ -13,7 +13,7 @@ dest: /etc/docker/daemon.json owner: root group: root - mode: 0644 + mode: 0o644 notify: docker diff --git a/resources/playbook/roles/bibigrid/tasks/042-slurm-server.yaml b/resources/playbook/roles/bibigrid/tasks/042-slurm-server.yaml index 5f6bb2d3..0a01914b 100644 --- a/resources/playbook/roles/bibigrid/tasks/042-slurm-server.yaml +++ b/resources/playbook/roles/bibigrid/tasks/042-slurm-server.yaml @@ -2,7 +2,7 @@ file: path: /etc/openstack/clouds.yaml group: slurm - mode: '0640' # (owner can read/write, group can read, others have no access) + mode: 0o640 # (owner can read/write, group can read, others have no access) - name: Create slurm db mysql_db: @@ -24,7 +24,7 @@ dest: /etc/slurm/slurmdbd.conf owner: slurm group: root - mode: "0600" + mode: 0o600 - name: Generate random JWT Secret command: @@ -36,7 +36,7 @@ path: /etc/slurm/jwt-secret.key owner: slurm group: slurm - mode: "0600" + mode: 0o600 - name: Copy env file for configuration of slurmrestd copy: @@ -44,14 +44,14 @@ dest: /etc/default/slurmrestd owner: root group: root - mode: "0644" + mode: 0o644 - name: Create system overrides directories (slurmdbdm slurmrestd) file: path: "/etc/systemd/system/{{ item }}.service.d" group: root owner: root - mode: "0755" + mode: 0o755 state: directory with_items: - slurmdbd @@ -61,7 +61,7 @@ copy: src: "slurm/systemd/{{ item }}.override" dest: "/etc/systemd/system/{{ item }}.service.d/override.conf" - mode: "0644" + mode: 0o644 owner: root group: root with_items: @@ -81,13 +81,13 @@ group: ansible path: /opt/slurm/ state: directory - mode: "0770" + mode: 0o770 - name: Ensures /etc/slurm dir exists file: path: /etc/slurm/ state: directory - mode: 0755 + mode: 0o755 - name: Ensures /opt/slurm/.ssh/ dir exists file: @@ -95,7 +95,7 @@ group: slurm owner: slurm state: directory - mode: 0700 + mode: 0o700 - name: Copy private key (openstack keypair) copy: @@ -103,7 +103,7 @@ dest: /opt/slurm/.ssh/id_ecdsa owner: slurm group: slurm - mode: "0600" + mode: 0o600 - name: Copy create program script (power) copy: @@ -111,7 +111,7 @@ dest: /opt/slurm/create.sh owner: slurm group: ansible - mode: "0550" + mode: 0o550 - name: Copy terminate program script (power) copy: @@ -119,7 +119,7 @@ dest: /opt/slurm/terminate.sh owner: slurm group: ansible - mode: "0550" + mode: 0o550 - name: Copy fail program script (power) copy: @@ -127,7 +127,7 @@ dest: /opt/slurm/fail.sh owner: slurm group: ansible - mode: "0550" + mode: 0o550 - name: Copy "create_server.py" script copy: @@ -135,7 +135,7 @@ dest: /usr/local/bin/create_server.py owner: slurm group: ansible - mode: "0750" + mode: 0o750 - name: Copy "delete_server.py" script copy: @@ -143,7 +143,7 @@ dest: /usr/local/bin/delete_server.py owner: slurm group: ansible - mode: "0750" + mode: 0o750 - name: Install python dependencies pip: @@ -169,7 +169,7 @@ dest: "/opt/slurm/userdata_{{ hostvars[item].cloud_identifier }}.txt" owner: slurm group: ansible - mode: "0640" + mode: 0o640 with_items: "{{ groups.vpngtw + groups.master }}" - name: Enable slurmdbd and slurmrestd services diff --git a/resources/playbook/roles/bibigrid/tasks/042-slurm.yaml b/resources/playbook/roles/bibigrid/tasks/042-slurm.yaml index d80fb67c..3008d3cb 100644 --- a/resources/playbook/roles/bibigrid/tasks/042-slurm.yaml +++ b/resources/playbook/roles/bibigrid/tasks/042-slurm.yaml @@ -16,7 +16,7 @@ Pin: version 23.11.* Pin-Priority: 1001 dest: /etc/apt/preferences.d/slurm-bibigrid - mode: '0311' + mode: 0o311 - name: Install slurm-bibigrid package apt: @@ -34,7 +34,7 @@ dest: /etc/munge/munge.key owner: munge group: munge - mode: 0600 + mode: 0o600 notify: - munge @@ -42,7 +42,7 @@ file: path: "{{ item }}" state: directory - mode: 0775 + mode: 0o775 owner: root group: slurm with_items: @@ -55,7 +55,7 @@ path: "/etc/systemd/system/{{ item }}.service.d" group: root owner: root - mode: "0755" + mode: 0o755 state: directory with_items: - slurmd @@ -65,7 +65,7 @@ copy: src: "slurm/systemd/{{ item }}.override" dest: "/etc/systemd/system/{{ item }}.service.d/override.conf" - mode: "0644" + mode: 0o644 owner: root group: root with_items: @@ -89,7 +89,7 @@ dest: /etc/slurm/slurm.conf owner: slurm group: root - mode: 0444 + mode: 0o444 - name: Create Job Container configuration template: @@ -97,7 +97,7 @@ dest: /etc/slurm/job_container.conf owner: slurm group: root - mode: 0444 + mode: 0o444 - name: Slurm cgroup configuration copy: @@ -105,7 +105,7 @@ dest: /etc/slurm/cgroup.conf owner: slurm group: root - mode: 0444 + mode: 0o444 - name: Restart slurmd systemd: