summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorColin Walters <walters@verbum.org>2019-10-10 19:24:28 +0000
committerColin Walters <walters@verbum.org>2019-10-11 12:57:59 +0000
commitca29a5b2f9d7b7e8d1548659085fa1fc475722d2 (patch)
tree466a9777585d2c8745dc220804a590c476adaa15
parentf39e097a815799bad704a8a1d8f16ee86f4c3602 (diff)
downloadpodman-ca29a5b2f9d7b7e8d1548659085fa1fc475722d2.tar.gz
podman-ca29a5b2f9d7b7e8d1548659085fa1fc475722d2.tar.bz2
podman-ca29a5b2f9d7b7e8d1548659085fa1fc475722d2.zip
Make user io.podman.service unit WantedBy=default.target
`multi-user.target` doesn't exist in the systemd *user* instance. We can't hook up the startup of a user unit to a system target. Doing so causes systemd to error out in Fedora CoreOS builds during presets. Make it depend on `default.target` instead. (Having the same unit in both system and user sessions has some tricky bits like this) Signed-off-by: Colin Walters <walters@verbum.org>
-rw-r--r--Makefile5
1 files changed, 4 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 735981d34..1e722b6fd 100644
--- a/Makefile
+++ b/Makefile
@@ -438,7 +438,10 @@ install.systemd:
install ${SELINUXOPT} -m 644 contrib/varlink/io.podman.socket ${DESTDIR}${SYSTEMDDIR}/io.podman.socket
install ${SELINUXOPT} -m 644 contrib/varlink/io.podman.socket ${DESTDIR}${USERSYSTEMDDIR}/io.podman.socket
install ${SELINUXOPT} -m 644 contrib/varlink/io.podman.service ${DESTDIR}${SYSTEMDDIR}/io.podman.service
- install ${SELINUXOPT} -m 644 contrib/varlink/io.podman.service ${DESTDIR}${USERSYSTEMDDIR}/io.podman.service
+ install ${SELINUXOPT} -d ${DESTDIR}${USERSYSTEMDDIR}
+ # User units are ordered differently, we can't make the *system* multi-user.target depend on a user unit.
+ # For user units the default.target that's the default is fine.
+ sed -e 's,^WantedBy=.*,WantedBy=default.target,' < contrib/varlink/io.podman.service > ${DESTDIR}${USERSYSTEMDDIR}/io.podman.service
install ${SELINUXOPT} -m 644 contrib/varlink/podman.conf ${DESTDIR}${TMPFILESDIR}/podman.conf
uninstall: