1 |
commit: b07a3c32ff4434204fc1d325497ec166d9c3b0d5 |
2 |
Author: Zac Medico <zmedico <AT> gentoo <DOT> org> |
3 |
AuthorDate: Mon Jan 7 20:09:01 2019 +0000 |
4 |
Commit: Zac Medico <zmedico <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon Jan 7 20:10:43 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b07a3c32 |
7 |
|
8 |
app-emulation/libpod: add init script a logrotate config |
9 |
|
10 |
Package-Manager: Portage-2.3.54, Repoman-2.3.12 |
11 |
Signed-off-by: Zac Medico <zmedico <AT> gentoo.org> |
12 |
|
13 |
app-emulation/libpod/files/podman.initd | 17 +++++++++++++++++ |
14 |
app-emulation/libpod/files/podman.logrotated | 7 +++++++ |
15 |
app-emulation/libpod/libpod-0.12.1.2.ebuild | 7 +++++++ |
16 |
3 files changed, 31 insertions(+) |
17 |
|
18 |
diff --git a/app-emulation/libpod/files/podman.initd b/app-emulation/libpod/files/podman.initd |
19 |
new file mode 100644 |
20 |
index 00000000000..b590be16a1b |
21 |
--- /dev/null |
22 |
+++ b/app-emulation/libpod/files/podman.initd |
23 |
@@ -0,0 +1,17 @@ |
24 |
+#!/sbin/openrc-run |
25 |
+# Copyright 2015-2019 Gentoo Authors |
26 |
+# Distributed under the terms of the GNU General Public License v2 |
27 |
+ |
28 |
+description="Podman Remote API Service" |
29 |
+LOG_PATH="/var/log/${RC_SVCNAME}" |
30 |
+RUN_PATH="/run/${RC_SVCNAME}" |
31 |
+pidfile="${RUN_PATH}/${RC_SVCNAME}.pid" |
32 |
+command="/usr/bin/podman" |
33 |
+command_args="--log-level debug varlink -t 0 unix:/run/podman/io.podman" |
34 |
+command_background="true" |
35 |
+start_stop_daemon_args="--stdout ${LOG_PATH}/${RC_SVCNAME}.log --stderr ${LOG_PATH}/${RC_SVCNAME}.log" |
36 |
+ |
37 |
+start() { |
38 |
+ checkpath -d "${RUN_PATH}" "${LOG_PATH}" |
39 |
+ default_start |
40 |
+} |
41 |
|
42 |
diff --git a/app-emulation/libpod/files/podman.logrotated b/app-emulation/libpod/files/podman.logrotated |
43 |
new file mode 100644 |
44 |
index 00000000000..b9d723451b0 |
45 |
--- /dev/null |
46 |
+++ b/app-emulation/libpod/files/podman.logrotated |
47 |
@@ -0,0 +1,7 @@ |
48 |
+/var/log/podman/podman.log { |
49 |
+ missingok |
50 |
+ size 5M |
51 |
+ rotate 3 |
52 |
+ compress |
53 |
+ copytruncate |
54 |
+} |
55 |
|
56 |
diff --git a/app-emulation/libpod/libpod-0.12.1.2.ebuild b/app-emulation/libpod/libpod-0.12.1.2.ebuild |
57 |
index b3bc6469606..80dbb5f4f19 100644 |
58 |
--- a/app-emulation/libpod/libpod-0.12.1.2.ebuild |
59 |
+++ b/app-emulation/libpod/libpod-0.12.1.2.ebuild |
60 |
@@ -96,4 +96,11 @@ src_install() { |
61 |
|
62 |
insinto /etc/containers |
63 |
newins test/registries.conf registries.conf.example |
64 |
+ |
65 |
+ newinitd "${FILESDIR}"/podman.initd podman |
66 |
+ |
67 |
+ insinto /etc/logrotate.d |
68 |
+ newins "${FILESDIR}/podman.logrotated" podman |
69 |
+ |
70 |
+ keepdir /var/lib/containers |
71 |
} |