mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2025-08-29 15:06:26 +02:00
Refactor systemctl services and timers
- Unified service templates into generic systemctl templates - Introduced reusable filter plugins for script path handling - Updated path variables and service/timer definitions - Migrated roles (backup, cleanup, repair, etc.) to use systemctl role - Added sys-daemon role for core systemd cleanup - Simplified timer handling via sys-timer role Note: This is a large refactor and some errors may still exist. Further testing and adjustments will be needed.
This commit is contained in:
@@ -2,10 +2,20 @@
|
||||
# Services
|
||||
|
||||
## Meta
|
||||
SYS_SERVICE_SUFFIX: ".{{ SOFTWARE_NAME | lower }}.service"
|
||||
SYS_SERVICE_SUFFIX: ".{{ SOFTWARE_NAME | lower }}.service"
|
||||
|
||||
## Names
|
||||
SYS_SERVICE_ALARM_CMP: "sys-ctl-alm-compose.{{ SOFTWARE_NAME }}@.service"
|
||||
SYS_SERVICE_CLEANUP_BACKUPS_OLD: "sys-ctl-cln-backups{{ SYS_SERVICE_SUFFIX }}"
|
||||
SYS_SERVICE_CLEANUP_BACKUPS_FAILED: "sys-ctl-cln-faild-bkps{{ SYS_SERVICE_SUFFIX }}"
|
||||
SYS_SERVICE_OPTIMIZE_DRIVE: "svc-opt-ssd-hdd{{ SYS_SERVICE_SUFFIX }}"
|
||||
SYS_SERVICE_BACKUP_RMT_2_LOC: "svc-bkp-rmt-2-loc{{ SYS_SERVICE_SUFFIX }}"
|
||||
SYS_SERVICE_REPAIR_DOCKER_HARD: "sys-ctl-rpr-docker-hard{{ SYS_SERVICE_SUFFIX }}"
|
||||
SYS_SERVICE_UPDATE_DOCKER: "update-docker{{ SYS_SERVICE_SUFFIX }}"
|
||||
|
||||
## On Failure
|
||||
SYS_SERVICE_ON_FAILURE_COMPOSE: "sys-ctl-alm-compose.{{ SOFTWARE_NAME }}@%i.service"
|
||||
SYS_SERVICE_ON_FAILURE_EMAIL: "sys-ctl-alm-email.{{ SOFTWARE_NAME }}@%i.service"
|
||||
SYS_SERVICE_ON_FAILURE_TELEGRAM: "sys-ctl-alm-telegram.{{ SOFTWARE_NAME }}@%i.service"
|
||||
|
||||
## Groups
|
||||
SYS_SERVICE_GROUP_BACKUPS: >
|
||||
@@ -36,5 +46,6 @@ SYS_SERVICE_GROUP_MANIPULATION: >
|
||||
SYS_SERVICE_GROUP_REPAIR +
|
||||
SYS_SERVICE_GROUP_OPTIMIZATION +
|
||||
SYS_SERVICE_GROUP_MAINTANANCE +
|
||||
[ 'update-docker' ]
|
||||
[ SYS_SERVICE_UPDATE_DOCKER ]
|
||||
}}
|
||||
|
||||
|
Reference in New Issue
Block a user