mirror of
https://gitlab.sectorq.eu/jaydee/ansible.git
synced 2025-07-01 15:38:33 +02:00
init
This commit is contained in:
13
playbooks/files/services/lcd_control.service
Normal file
13
playbooks/files/services/lcd_control.service
Normal file
@ -0,0 +1,13 @@
|
||||
[Unit]
|
||||
Description=Led Control service
|
||||
Wants=network-online.target
|
||||
After=network.target network-online.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=root
|
||||
#ExecStartPre=/bin/sleep 30
|
||||
ExecStart=/usr/bin/python3 /usr/bin/lcd_control.py
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target suspend.target hibernate.target hybrid-sleep.target suspend-then-hibernate.target
|
14
playbooks/files/services/lcd_control_restart.service
Normal file
14
playbooks/files/services/lcd_control_restart.service
Normal file
@ -0,0 +1,14 @@
|
||||
[Unit]
|
||||
Description=Run my custom task at shutdown only
|
||||
DefaultDependencies=no
|
||||
Before=poweroff.target halt.target shutdown.target reboot.target
|
||||
Requires=poweroff.target
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
ExecStartPre=systemctl stop lcd_control.service
|
||||
ExecStart=/usr/bin/python3 /usr/bin/lcd_control_restart.py
|
||||
RemainAfterExit=yes
|
||||
|
||||
[Install]
|
||||
WantedBy=shutdown.target
|
11
playbooks/files/services/lcd_control_start.service
Normal file
11
playbooks/files/services/lcd_control_start.service
Normal file
@ -0,0 +1,11 @@
|
||||
[Unit]
|
||||
Description=Run my custom task at shutdown only
|
||||
After=syslog.target
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
ExecStart=/usr/bin/python3 /usr/bin/lcd_control_start.py
|
||||
RemainAfterExit=yes
|
||||
|
||||
[Install]
|
||||
WantedBy=basic.target
|
16
playbooks/files/services/rhasspy.service
Normal file
16
playbooks/files/services/rhasspy.service
Normal file
@ -0,0 +1,16 @@
|
||||
[Unit]
|
||||
Description=Rhasspy Autostart
|
||||
After=network-online.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=jd
|
||||
WorkingDirectory=/home/jd
|
||||
ExecStart=/bin/bash -lc '/usr/bin/rhasspy --profile en 2>&1 | cat'
|
||||
StandardOutput=inherit
|
||||
StandardError=inherit
|
||||
Restart=always
|
||||
RestartSec=20
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
Reference in New Issue
Block a user