2019-08-19 10:34:37 +00:00
|
|
|
diff -up cups-2.2.12/scheduler/main.c.systemd-socket cups-2.2.12/scheduler/main.c
|
|
|
|
--- cups-2.2.12/scheduler/main.c.systemd-socket 2019-08-16 00:35:30.000000000 +0200
|
|
|
|
+++ cups-2.2.12/scheduler/main.c 2019-08-19 09:31:09.703370325 +0200
|
|
|
|
@@ -674,8 +674,16 @@ main(int argc, /* I - Number of comm
|
2015-01-27 11:06:16 +00:00
|
|
|
|
2017-10-17 17:21:25 +00:00
|
|
|
#ifdef HAVE_ONDEMAND
|
2015-01-27 11:06:16 +00:00
|
|
|
if (OnDemand)
|
|
|
|
+ {
|
2014-09-12 16:19:24 +00:00
|
|
|
cupsdAddEvent(CUPSD_EVENT_SERVER_STARTED, NULL, NULL, "Scheduler started on demand.");
|
2015-01-27 11:06:16 +00:00
|
|
|
- else
|
|
|
|
+# ifdef HAVE_SYSTEMD
|
|
|
|
+ sd_notifyf(0, "READY=1\n"
|
|
|
|
+ "STATUS=Scheduler is running...\n"
|
|
|
|
+ "MAINPID=%lu",
|
|
|
|
+ (unsigned long) getpid());
|
|
|
|
+# endif /* HAVE_SYSTEMD */
|
|
|
|
+ } else
|
2017-10-17 17:21:25 +00:00
|
|
|
+
|
2016-06-27 16:29:55 +00:00
|
|
|
#endif /* HAVE_ONDEMAND */
|
2014-04-17 14:59:54 +00:00
|
|
|
if (fg)
|
2014-09-12 16:19:24 +00:00
|
|
|
cupsdAddEvent(CUPSD_EVENT_SERVER_STARTED, NULL, NULL, "Scheduler started in foreground.");
|
2019-08-19 10:34:37 +00:00
|
|
|
diff -up cups-2.2.12/scheduler/org.cups.cupsd.path.in.systemd-socket cups-2.2.12/scheduler/org.cups.cupsd.path.in
|
|
|
|
--- cups-2.2.12/scheduler/org.cups.cupsd.path.in.systemd-socket 2019-08-16 00:35:30.000000000 +0200
|
|
|
|
+++ cups-2.2.12/scheduler/org.cups.cupsd.path.in 2019-08-19 09:31:09.703370325 +0200
|
2018-09-19 09:59:44 +00:00
|
|
|
@@ -1,6 +1,6 @@
|
|
|
|
[Unit]
|
|
|
|
Description=CUPS Scheduler
|
|
|
|
-PartOf=org.cups.cupsd.service
|
|
|
|
+PartOf=cups.service
|
2014-09-12 16:19:24 +00:00
|
|
|
|
|
|
|
[Path]
|
2018-09-19 09:59:44 +00:00
|
|
|
PathExists=@CUPS_CACHEDIR@/org.cups.cupsd
|
2019-08-19 10:34:37 +00:00
|
|
|
diff -up cups-2.2.12/scheduler/org.cups.cupsd.service.in.systemd-socket cups-2.2.12/scheduler/org.cups.cupsd.service.in
|
|
|
|
--- cups-2.2.12/scheduler/org.cups.cupsd.service.in.systemd-socket 2019-08-19 09:31:09.703370325 +0200
|
|
|
|
+++ cups-2.2.12/scheduler/org.cups.cupsd.service.in 2019-08-19 09:54:58.890036404 +0200
|
|
|
|
@@ -1,13 +1,13 @@
|
2014-11-15 14:42:30 +00:00
|
|
|
[Unit]
|
2014-09-12 16:19:24 +00:00
|
|
|
Description=CUPS Scheduler
|
2014-11-15 14:42:30 +00:00
|
|
|
Documentation=man:cupsd(8)
|
2019-08-19 10:34:37 +00:00
|
|
|
-After=sssd.service
|
|
|
|
+After=sssd.service network.target
|
2014-09-12 16:19:24 +00:00
|
|
|
|
|
|
|
[Service]
|
2015-01-27 11:06:16 +00:00
|
|
|
ExecStart=@sbindir@/cupsd -l
|
2014-09-12 16:19:24 +00:00
|
|
|
-Type=simple
|
|
|
|
+Type=notify
|
2018-06-27 14:21:32 +00:00
|
|
|
Restart=on-failure
|
2011-08-05 14:11:04 +00:00
|
|
|
|
2014-09-12 16:19:24 +00:00
|
|
|
[Install]
|
2018-09-19 09:59:44 +00:00
|
|
|
-Also=org.cups.cupsd.socket org.cups.cupsd.path
|
|
|
|
+Also=cups.socket cups.path
|
|
|
|
WantedBy=printer.target
|
2019-08-19 10:34:37 +00:00
|
|
|
diff -up cups-2.2.12/scheduler/org.cups.cupsd.socket.in.systemd-socket cups-2.2.12/scheduler/org.cups.cupsd.socket.in
|
|
|
|
--- cups-2.2.12/scheduler/org.cups.cupsd.socket.in.systemd-socket 2019-08-16 00:35:30.000000000 +0200
|
|
|
|
+++ cups-2.2.12/scheduler/org.cups.cupsd.socket.in 2019-08-19 09:31:09.703370325 +0200
|
2018-09-19 09:59:44 +00:00
|
|
|
@@ -1,6 +1,6 @@
|
|
|
|
[Unit]
|
|
|
|
Description=CUPS Scheduler
|
|
|
|
-PartOf=org.cups.cupsd.service
|
|
|
|
+PartOf=cups.service
|
|
|
|
|
|
|
|
[Socket]
|
|
|
|
ListenStream=@CUPS_DEFAULT_DOMAINSOCKET@
|
2019-08-19 10:34:37 +00:00
|
|
|
diff -up cups-2.2.12/scheduler/org.cups.cups-lpd.socket.systemd-socket cups-2.2.12/scheduler/org.cups.cups-lpd.socket
|
|
|
|
--- cups-2.2.12/scheduler/org.cups.cups-lpd.socket.systemd-socket 2019-08-16 00:35:30.000000000 +0200
|
|
|
|
+++ cups-2.2.12/scheduler/org.cups.cups-lpd.socket 2019-08-19 09:31:09.703370325 +0200
|
2018-09-19 09:59:44 +00:00
|
|
|
@@ -1,6 +1,6 @@
|
|
|
|
[Unit]
|
|
|
|
Description=CUPS LPD Server Socket
|
|
|
|
-PartOf=org.cups.cups-lpd.service
|
|
|
|
+PartOf=cups-lpd.service
|
|
|
|
|
|
|
|
[Socket]
|
|
|
|
ListenStream=515
|