When you create two or more custom systemd services, how do you know which order they will be run? And will that order be sure thing?
I am doing Type = idle which is supposed to mean
Behavior of idle is very similar to simple; however, actual execution of the service program is delayed until all active jobs are dispatched. This may be used to avoid interleaving of output of shell services with the status output on the console. Note that this type is useful only to improve console output, it is not useful as a general unit ordering tool, and the effect of this service type is subject to a 5s timeout, after which the service program is invoked anyway
Below is my /etc/systemd/system/myservice1.service
#!/bin/bash
[Unit]
Description=my service
After=default.target
[Service]
Type=idle
ExecStart=/root/my_service1.sh
TimeoutStartSec=0
[Install]
WantedBy=default.target
I then do
{ create /root/my_service.sh }
chmod 700 /root/my_service1.sh
systemctl daemon-reload
systemctl enable my_service1
If I create many services of type idle, how do I know which order these services will be run in? I do want them to only happen after the system has fully booted and everything boot related has finished.
I then plan on having a few custom do_this.service
and do_that.service
. I have not yet decided how I am naming everything.