mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2025-08-29 15:06:26 +02:00
initial cleanup server-manager
This commit is contained in:
4
roles/native-docker-volume-backup/handlers/main.yml
Normal file
4
roles/native-docker-volume-backup/handlers/main.yml
Normal file
@@ -0,0 +1,4 @@
|
||||
- name: restart docker-volume-backup service
|
||||
service: name=docker-volume-backup.service state=restarted enabled=yes
|
||||
- name: restart docker-volume-backup timer
|
||||
service: name=docker-volume-backup.timer state=restarted enabled=yes
|
3
roles/native-docker-volume-backup/meta/main.yml
Normal file
3
roles/native-docker-volume-backup/meta/main.yml
Normal file
@@ -0,0 +1,3 @@
|
||||
dependencies:
|
||||
- native-docker
|
||||
- native-git
|
13
roles/native-docker-volume-backup/tasks/main.yml
Normal file
13
roles/native-docker-volume-backup/tasks/main.yml
Normal file
@@ -0,0 +1,13 @@
|
||||
- name: docker-volume-backup git
|
||||
git:
|
||||
repo: "https://github.com/kevinveenbirkenbach/docker-volume-backup.git"
|
||||
dest: "/usr/local/bin/docker-volume-backup"
|
||||
update: yes
|
||||
|
||||
- name: configure docker-volume-backup.service.tpl
|
||||
template: src=docker-volume-backup.service dest=/etc/systemd/system/docker-volume-backup.service
|
||||
notify: restart docker-volume-backup service
|
||||
|
||||
- name: configure docker-volume-backup.timer.tpl
|
||||
template: src=docker-volume-backup.timer dest=/etc/systemd/system/docker-volume-backup.timer
|
||||
notify: restart docker-volume-backup timer
|
@@ -0,0 +1,6 @@
|
||||
[Unit]
|
||||
Description=docker volume update
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
ExecStart=/usr/bin/bash /usr/local/bin/docker-volume-backup/docker-volume-backup.sh
|
@@ -0,0 +1,9 @@
|
||||
[Unit]
|
||||
Description=backups the docker volumes
|
||||
|
||||
[Timer]
|
||||
OnCalendar=3:00
|
||||
RandomizedDelaySec=1h
|
||||
|
||||
[Install]
|
||||
WantedBy=timers.target
|
Reference in New Issue
Block a user