Set ordering and dependency relationship.

Section: Environment, Users, Dependencies

Start after another unit

ini
ini
[Unit]
Wants=network-online.target
After=network-online.target
Explanation

Common for network-dependent apps.

Learn the surrounding workflow

Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.

Related commands

Same sheet · prioritizing Environment, Users, Dependencies
Load variables from EnvironmentFile
Use an external env file.
OpenIn sheetinisame section
Run service as non-root user
Specify service user and group.
OpenIn sheetinisame section
Set working directory
Run service from a specific directory.
OpenIn sheetinisame section
Require another unit
Fail if the required unit is absent or stopped.
OpenIn sheetinisame section
Create custom service file
Open a new service file under /etc/systemd/system.
OpenIn sheetbash1 tag match
Restart on failure
Automatic restart policy.
OpenIn sheetini1 tag match