]> git.pld-linux.org Git - packages/docker.git/commitdiff
Add systemd unit
authorAria Stewart <aredridel@nbtsc.org>
Fri, 29 Nov 2013 00:48:06 +0000 (17:48 -0700)
committerAria Stewart <aredridel@nbtsc.org>
Fri, 29 Nov 2013 00:48:06 +0000 (17:48 -0700)
lxc-docker.service [new file with mode: 0644]
lxc-docker.spec

diff --git a/lxc-docker.service b/lxc-docker.service
new file mode 100644 (file)
index 0000000..42ce05d
--- /dev/null
@@ -0,0 +1,13 @@
+[Unit]
+Description=Docker Application Container Engine
+Documentation=http://docs.docker.io
+Requires=network.target
+After=syslog.target network.target remote-fs.target nss-lookup.target
+
+[Service]
+Type=simple
+ExecStartPre=/bin/mount --make-rprivate /
+ExecStart=/usr/bin/docker -d
+
+[Install]
+WantedBy=multi-user.target
index 0086ee285123876015a38a463ffcb60efa71cd8d..bea1f81ce05c6def511a67ae6a0684c1dcb7e299 100644 (file)
@@ -10,6 +10,7 @@ License:      Apache v2.0
 Group:         Applications/System
 Source0:       https://github.com/dotcloud/docker/archive/v%{version}/docker-%{version}.tar.gz
 # Source0-md5: bc5e2aa1fbcd3ab8fac1a4f6a4613a16
+Source5:       %{name}.service
 Source6:       %{name}.init
 URL:           http://github.com/dotcloud/docker
 BuildRequires: device-mapper-devel
@@ -102,9 +103,10 @@ go build -v -ldflags "$LDFLAGS" -a ../dockerinit/dockerinit.go
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT{%{_bindir},%{_mandir}/man1,/etc/rc.d/init.d,/var/lib/docker/{containers,graph,volumes}}
+install -d $RPM_BUILD_ROOT{%{_bindir},%{_mandir}/man1,/etc/rc.d/init.d,%{systemdunitdir},/var/lib/docker/{containers,graph,volumes}}
 install -p build/docker $RPM_BUILD_ROOT%{_bindir}/lxc-docker
 install -p build/dockerinit $RPM_BUILD_ROOT%{_bindir}/dockerinit
+install -p %{SOURCE5} $RPM_BUILD_ROOT%{systemdunitdir}/lxc-docker.service
 install -p %{SOURCE6} $RPM_BUILD_ROOT/etc/rc.d/init.d/lxc-docker
 ln -s lxc-docker $RPM_BUILD_ROOT%{_bindir}/docker
 #cp -p packaging/debian/lxc-docker.1 $RPM_BUILD_ROOT%{_mandir}/man1
@@ -143,6 +145,7 @@ rm -rf $RPM_BUILD_ROOT
 %files
 %defattr(644,root,root,755)
 %doc README.md CHANGELOG.md CONTRIBUTING.md FIXME LICENSE AUTHORS NOTICE MAINTAINERS
+%attr(644,root,root) %{systemdunitdir}/lxc-docker.service
 %attr(754,root,root) /etc/rc.d/init.d/lxc-docker
 %attr(755,root,root) %{_bindir}/lxc-docker
 %attr(755,root,root) %{_bindir}/docker
This page took 0.034527 seconds and 4 git commands to generate.