diff --git a/src/rhcsa.md b/src/rhcsa.md index 18b57d4..66106c9 100644 --- a/src/rhcsa.md +++ b/src/rhcsa.md @@ -264,21 +264,24 @@ sudo systemctl unmask sshd # Unmask the sshd service sudo nano /etc/systemd/system/myapp.service # [Unit] # Description=My App -# After=network.target # [Service] +# Type=simple # ExecStart=/usr/bin/myapp +# User=myuser ### Creating a timer ### sudo nano /etc/systemd/system/myapp.timer # [Unit] # Description=My App Timer -# After=myapp.service # [Timer] -# OnBootSec=10min -# OnCalendar=daily +# OnBootSec=10min # Run the timer 10 minutes after the system starts +# OnCalendar=*-*-* 10:00:00 # Run at 10:00 AM every day + +# [Install] +# WantedBy=graphical.target # Run the timer on the graphical target ### Tying the timer to the service ### sudo systemctl link /etc/systemd/system/myapp.timer