[glib-networking] Add a systemd user unit corresponding to the libproxy runner D-Bus service
- From: Simon McVittie <smcv src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glib-networking] Add a systemd user unit corresponding to the libproxy runner D-Bus service
- Date: Mon, 28 Sep 2015 20:22:05 +0000 (UTC)
commit df0013e681e4c64ae404c32b62aeef4d55339517
Author: Simon McVittie <simon mcvittie collabora co uk>
Date: Fri Sep 25 16:25:33 2015 +0100
Add a systemd user unit corresponding to the libproxy runner D-Bus service
This puts it in its own cgroup when running under systemd with
dbus-daemon.
Bug: https://bugzilla.gnome.org/show_bug.cgi?id=755740
Reviewed-by: Dan Winship <danw gnome org>
proxy/libproxy/Makefile.am | 10 ++++++++++
proxy/libproxy/glib-pacrunner.service.in | 7 +++++++
proxy/libproxy/org.gtk.GLib.PACRunner.service.in | 1 +
3 files changed, 18 insertions(+), 0 deletions(-)
---
diff --git a/proxy/libproxy/Makefile.am b/proxy/libproxy/Makefile.am
index 7d0453e..a386827 100644
--- a/proxy/libproxy/Makefile.am
+++ b/proxy/libproxy/Makefile.am
@@ -40,3 +40,13 @@ CLEANFILES += $(service_DATA)
org.gtk.GLib.PACRunner.service: org.gtk.GLib.PACRunner.service.in Makefile
$(AM_V_GEN) sed -e "s|\ libexecdir\@|$(libexecdir)|" $< > $@
+
+systemd_userdir = $(prefix)/lib/systemd/user
+systemd_user_in_files = glib-pacrunner.service.in
+systemd_user_DATA = $(systemd_user_in_files:.service.in=.service)
+
+EXTRA_DIST += $(systemd_user_in_files)
+CLEANFILES += $(systemd_user_DATA)
+
+glib-pacrunner.service: glib-pacrunner.service.in Makefile
+ $(AM_V_GEN) sed -e "s|\ libexecdir\@|$(libexecdir)|" $< > $@
diff --git a/proxy/libproxy/glib-pacrunner.service.in b/proxy/libproxy/glib-pacrunner.service.in
new file mode 100644
index 0000000..0f289de
--- /dev/null
+++ b/proxy/libproxy/glib-pacrunner.service.in
@@ -0,0 +1,7 @@
+[Unit]
+Description=GLib proxy auto-configuration service
+
+[Service]
+Type=dbus
+BusName=org.gtk.GLib.PACRunner
+ExecStart= libexecdir@/glib-pacrunner
diff --git a/proxy/libproxy/org.gtk.GLib.PACRunner.service.in
b/proxy/libproxy/org.gtk.GLib.PACRunner.service.in
index df736ce..f1bd699 100644
--- a/proxy/libproxy/org.gtk.GLib.PACRunner.service.in
+++ b/proxy/libproxy/org.gtk.GLib.PACRunner.service.in
@@ -1,3 +1,4 @@
[D-BUS Service]
Name=org.gtk.GLib.PACRunner
Exec= libexecdir@/glib-pacrunner
+SystemdService=glib-pacrunner.service
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]