> you’ll see a WantedBy line. This is a great place to set up container dependencies. In this example, the container that runs caddy (a web server) can’t start until Wordpress is up and running. Either this must be some systemd weirdness that I thankfully haven't had to deal with until now, or I'm misunderstanding something. Did I understand correctly you don't specify which services you need but rather which ones de…
[Install]
WantedBy=multi-user.target
This is the mechanism by which one unit can ask to be added to the Wants= of another when it is installed.i.e., when you run 'systemctl enable whatever.service', it will be symlinked into '/etc/systemd/system/multi-user.target.wants'. And 'systemctl show multi-user.target' will show 'whatever.service' in its Wants property.
https://www.freedesktop.org/software/systemd/man/systemd.uni...
During bootup of a headless system, the 'default' target is usually multi-user.target, so what we've done here is ensure that whatever.service will be started before the machine finishes booting.
https://www.freedesktop.org/software/systemd/man/bootup.html