Skip to content

Commit

Permalink
app-emulation/libpod: add init script a logrotate config
Browse files Browse the repository at this point in the history
Package-Manager: Portage-2.3.54, Repoman-2.3.12
Signed-off-by: Zac Medico <[email protected]>
  • Loading branch information
zmedico committed Jan 7, 2019
1 parent 2c00aa5 commit b07a3c3
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 0 deletions.
17 changes: 17 additions & 0 deletions app-emulation/libpod/files/podman.initd
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#!/sbin/openrc-run
# Copyright 2015-2019 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

description="Podman Remote API Service"
LOG_PATH="/var/log/${RC_SVCNAME}"
RUN_PATH="/run/${RC_SVCNAME}"
pidfile="${RUN_PATH}/${RC_SVCNAME}.pid"
command="/usr/bin/podman"
command_args="--log-level debug varlink -t 0 unix:/run/podman/io.podman"
command_background="true"
start_stop_daemon_args="--stdout ${LOG_PATH}/${RC_SVCNAME}.log --stderr ${LOG_PATH}/${RC_SVCNAME}.log"

start() {
checkpath -d "${RUN_PATH}" "${LOG_PATH}"
default_start
}
7 changes: 7 additions & 0 deletions app-emulation/libpod/files/podman.logrotated
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
/var/log/podman/podman.log {
missingok
size 5M
rotate 3
compress
copytruncate
}
7 changes: 7 additions & 0 deletions app-emulation/libpod/libpod-0.12.1.2.ebuild
Original file line number Diff line number Diff line change
Expand Up @@ -96,4 +96,11 @@ src_install() {

insinto /etc/containers
newins test/registries.conf registries.conf.example

newinitd "${FILESDIR}"/podman.initd podman

insinto /etc/logrotate.d
newins "${FILESDIR}/podman.logrotated" podman

keepdir /var/lib/containers
}

0 comments on commit b07a3c3

Please sign in to comment.