feat: initial commit

This commit is contained in:
Simon Cornet 2025-05-06 10:58:34 +02:00
commit 0c58302da5
20 changed files with 326 additions and 0 deletions

32
tasks/tmpfs.yaml Normal file
View file

@ -0,0 +1,32 @@
---
# create /var/log/remote directory
- name: "create /var/log/remote directory"
ansible.builtin.file:
path: "/var/log/remote"
state: "directory"
mode: "0755"
# create systemd mount unit
- name: "create systemd mount unit for /var/log/remote"
ansible.builtin.copy:
dest: "/etc/systemd/system/var-log-remote.mount"
content: |
[Unit]
Description=Mount tmpfs to /var/log/remote
Before=local-fs.target
Before=rsyslog.service
DefaultDependencies=no
[Mount]
What=tmpfs
Where=/var/log/remote
Type=tmpfs
Options=defaults,size=512M
[Install]
WantedBy=multi-user.target
owner: "root"
group: "root"
mode: "0644"
notify: "var-log-remote-unit"