Merge lp:~jderose/dmedia/systemd into lp:dmedia

Proposed by Jason Gerard DeRose
Status: Merged
Merged at revision: 939
Proposed branch: lp:~jderose/dmedia/systemd
Merge into: lp:dmedia
Diff against target: 91 lines (+12/-32)
7 files modified
dbus-activation-hack.sh (+0/-19)
debian/dmedia.install (+1/-0)
debian/dmedia.user-session.upstart (+0/-10)
debian/rules (+0/-1)
dmedia.service (+9/-0)
setup.py (+0/-1)
share/org.freedesktop.Dmedia.service (+2/-1)
To merge this branch: bzr merge lp:~jderose/dmedia/systemd
Reviewer Review Type Date Requested Status
David Jordan Approve
Review via email: mp+376554@code.launchpad.net

Commit message

Adds initial support for running Dmedia as a systemd user service.

To post a comment you must log in.
Revision history for this message
David Jordan (dmj726) wrote :

This looks good to me. One thing is to make sure it autostarts. Unless there's a better way, one way would be to call the service from a script in /etc/xdg/autostart/ but let systemd manage it from there forward.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== removed file 'dbus-activation-hack.sh'
--- dbus-activation-hack.sh 2014-05-24 05:09:55 +0000
+++ dbus-activation-hack.sh 1970-01-01 00:00:00 +0000
@@ -1,19 +0,0 @@
1#!/bin/sh
2
3# Based on script of the same name in the Ubuntu 13.10 `hud` package.
4# We should be able to drop this as soon as we drop 13.10 support.
5#
6# Original comment:
7# This is a quick hack to make it so that DBus activation works as the
8# DBus daemon holds onto the PID until the name gets registered. So we
9# need the PID to exist until then. 10 seconds should be more that enough
10# time for the service to register the name.
11#
12# This can go away if we get DBus Activation for Upstart
13
14if [ "x$UPSTART_SESSION" != "x" ]; then
15 start dmedia
16 sleep 5
17else
18 /usr/lib/dmedia/dmedia-service
19fi
200
=== modified file 'debian/dmedia.install'
--- debian/dmedia.install 2013-02-21 10:50:22 +0000
+++ debian/dmedia.install 2019-12-10 02:19:02 +0000
@@ -1,1 +1,2 @@
1debian/source_dmedia.py usr/share/apport/package-hooks/1debian/source_dmedia.py usr/share/apport/package-hooks/
2dmedia.service usr/lib/systemd/user/
23
=== removed file 'debian/dmedia.user-session.upstart'
--- debian/dmedia.user-session.upstart 2013-12-12 20:11:58 +0000
+++ debian/dmedia.user-session.upstart 1970-01-01 00:00:00 +0000
@@ -1,10 +0,0 @@
1# Dmedia - a distributed object store aimed at professional content creation
2
3description "Start the per user Dmedia instance"
4author "Jason Gerard DeRose <jderose@novacut.com>"
5
6start on desktop-start
7stop on desktop-end
8respawn
9
10exec /usr/lib/dmedia/dmedia-service
110
=== modified file 'debian/rules'
--- debian/rules 2014-09-28 03:04:13 +0000
+++ debian/rules 2019-12-10 02:19:02 +0000
@@ -25,5 +25,4 @@
25 --install-layout=deb \25 --install-layout=deb \
26 --root=$(CURDIR)/debian/dmedia; \26 --root=$(CURDIR)/debian/dmedia; \
27 done27 done
28 install -m 644 -D debian/dmedia.user-session.upstart debian/dmedia/usr/share/upstart/sessions/dmedia.conf
2928
3029
=== added file 'dmedia.service'
--- dmedia.service 1970-01-01 00:00:00 +0000
+++ dmedia.service 2019-12-10 02:19:02 +0000
@@ -0,0 +1,9 @@
1[Unit]
2Description=Dmedia Distributed Object Store
3
4[Service]
5Type=dbus
6BusName=org.freedesktop.Dmedia
7ExecStart=/usr/lib/dmedia/dmedia-service
8Restart=on-failure
9
010
=== modified file 'setup.py'
--- setup.py 2015-11-21 19:32:59 +0000
+++ setup.py 2019-12-10 02:19:02 +0000
@@ -217,7 +217,6 @@
217 ),217 ),
218 ('lib/dmedia', [218 ('lib/dmedia', [
219 'dmedia-service',219 'dmedia-service',
220 'dbus-activation-hack.sh',
221 'dmedia-transcoder',220 'dmedia-transcoder',
222 ]221 ]
223 ),222 ),
224223
=== modified file 'share/org.freedesktop.Dmedia.service'
--- share/org.freedesktop.Dmedia.service 2013-12-11 14:55:01 +0000
+++ share/org.freedesktop.Dmedia.service 2019-12-10 02:19:02 +0000
@@ -1,3 +1,4 @@
1[D-BUS Service]1[D-BUS Service]
2Name=org.freedesktop.Dmedia2Name=org.freedesktop.Dmedia
3Exec=/usr/lib/dmedia/dbus-activation-hack.sh3SystemdService=dmedia.service
4Exec=/usr/lib/dmedia/dmedia-service

Subscribers

People subscribed via source and target branches