From c3a68a71071fca48dc22174dbc6e3fe379e2579a Mon Sep 17 00:00:00 2001 From: Erik Mackdanz Date: Wed, 6 Feb 2019 22:28:28 -0600 Subject: sys-fs/lxcfs: Bump to 3.0.3 Signed-off-by: Erik Mackdanz Package-Manager: Portage-2.3.59, Repoman-2.3.12 --- sys-fs/lxcfs/Manifest | 1 + .../lxcfs/files/lxcfs-3.0.2-fusermount-path.patch | 15 ----- sys-fs/lxcfs/files/lxcfs-3.0.2.initd | 26 -------- sys-fs/lxcfs/files/lxcfs-fusermount-path.patch | 15 +++++ sys-fs/lxcfs/files/lxcfs.initd | 26 ++++++++ sys-fs/lxcfs/lxcfs-3.0.2.ebuild | 4 +- sys-fs/lxcfs/lxcfs-3.0.3.ebuild | 72 ++++++++++++++++++++++ 7 files changed, 116 insertions(+), 43 deletions(-) delete mode 100644 sys-fs/lxcfs/files/lxcfs-3.0.2-fusermount-path.patch delete mode 100644 sys-fs/lxcfs/files/lxcfs-3.0.2.initd create mode 100644 sys-fs/lxcfs/files/lxcfs-fusermount-path.patch create mode 100644 sys-fs/lxcfs/files/lxcfs.initd create mode 100644 sys-fs/lxcfs/lxcfs-3.0.3.ebuild (limited to 'sys-fs') diff --git a/sys-fs/lxcfs/Manifest b/sys-fs/lxcfs/Manifest index 8b3d028d5c34..c9df8779225c 100644 --- a/sys-fs/lxcfs/Manifest +++ b/sys-fs/lxcfs/Manifest @@ -1,2 +1,3 @@ DIST lxcfs-3.0.0.tar.gz 49219 BLAKE2B c21cd9983e9175bf3a31bafd8a29ddd6a6a549226bd432636dd4ea48bf6268c403f236ca39739a989cd89fa7b0b05043c179ca328fd739f5a9d56e27907a7a60 SHA512 99fe11e99c2e487d6ecd9a8484be6413563ddcb33740631ee6fe1b60d3d2d62cea1bb44d1ef6dc45283f5b3d20cd680d48ea3cb5ad17f0c3e7ba6ed56186c42f DIST lxcfs-3.0.2.tar.gz 49809 BLAKE2B dc73149b92ac040c56de5f4c11aafdf6e744ffd2b17e22ee9c784663ff102dedd74453581a77027037955238e081c596377c28b6066012fa32ee575e6a4c57fa SHA512 2065bbd68fd2974fe28c861b1e77c62a501da85e1bfc19eeafa49fd88c66e8e75ae007781c8bd05caf43fb3b80ad12c81c0f0f03d27ab1131e0cfe6d48443218 +DIST lxcfs-3.0.3.tar.gz 49824 BLAKE2B 02e3a0a6f4fd515924c5f038f00d664ef347c9b685e6561334b460e0ce0ce5580aca67f33df56b44b9cdafa4953f4f92843662f3516e1c923f9242388b17dbc6 SHA512 d994e1dd85f499eba2847d33870281a4bcaf4466e2c8f7acb065f4f3d5688b93b775c486bc6db571e64d09a3567710b0c816e12555ffb3e3e50f81bc7f5f6be6 diff --git a/sys-fs/lxcfs/files/lxcfs-3.0.2-fusermount-path.patch b/sys-fs/lxcfs/files/lxcfs-3.0.2-fusermount-path.patch deleted file mode 100644 index 99a5addf1d10..000000000000 --- a/sys-fs/lxcfs/files/lxcfs-3.0.2-fusermount-path.patch +++ /dev/null @@ -1,15 +0,0 @@ ---- /config/init/systemd/lxcfs.service.orig 2018-10-13 17:24:46.534035126 -0500 -+++ /config/init/systemd/lxcfs.service 2018-10-13 17:25:33.007034294 -0500 -@@ -5,10 +5,10 @@ - Documentation=man:lxcfs(1) - - [Service] --ExecStart=/usr/bin/lxcfs /var/lib/lxcfs/ -+ExecStart=/usr/bin/lxcfs -o allow_other,nonempty /var/lib/lxcfs/ - KillMode=process - Restart=on-failure --ExecStopPost=-/bin/fusermount -u /var/lib/lxcfs -+ExecStopPost=-/usr/bin/fusermount -u /var/lib/lxcfs - Delegate=yes - - [Install] diff --git a/sys-fs/lxcfs/files/lxcfs-3.0.2.initd b/sys-fs/lxcfs/files/lxcfs-3.0.2.initd deleted file mode 100644 index 52d8202d7ac3..000000000000 --- a/sys-fs/lxcfs/files/lxcfs-3.0.2.initd +++ /dev/null @@ -1,26 +0,0 @@ -#!/sbin/openrc-run -# Copyright 1999-2018 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -DAEMON=/usr/bin/lxcfs -PIDFILE=/run/lxcfs.pid - -start() { - ebegin "Starting lxcfs" - - start-stop-daemon --start \ - --pidfile ${PIDFILE} \ - --exec ${DAEMON} \ - --background \ - --make-pidfile \ - -- \ - -o allow_other,nonempty /var/lib/lxcfs - - eend $? -} - -stop() { - ebegin "Stopping lxcfs" - start-stop-daemon --stop --quiet -R TERM/45 -p ${PIDFILE} - eend $? -} diff --git a/sys-fs/lxcfs/files/lxcfs-fusermount-path.patch b/sys-fs/lxcfs/files/lxcfs-fusermount-path.patch new file mode 100644 index 000000000000..99a5addf1d10 --- /dev/null +++ b/sys-fs/lxcfs/files/lxcfs-fusermount-path.patch @@ -0,0 +1,15 @@ +--- /config/init/systemd/lxcfs.service.orig 2018-10-13 17:24:46.534035126 -0500 ++++ /config/init/systemd/lxcfs.service 2018-10-13 17:25:33.007034294 -0500 +@@ -5,10 +5,10 @@ + Documentation=man:lxcfs(1) + + [Service] +-ExecStart=/usr/bin/lxcfs /var/lib/lxcfs/ ++ExecStart=/usr/bin/lxcfs -o allow_other,nonempty /var/lib/lxcfs/ + KillMode=process + Restart=on-failure +-ExecStopPost=-/bin/fusermount -u /var/lib/lxcfs ++ExecStopPost=-/usr/bin/fusermount -u /var/lib/lxcfs + Delegate=yes + + [Install] diff --git a/sys-fs/lxcfs/files/lxcfs.initd b/sys-fs/lxcfs/files/lxcfs.initd new file mode 100644 index 000000000000..5997426fa8e8 --- /dev/null +++ b/sys-fs/lxcfs/files/lxcfs.initd @@ -0,0 +1,26 @@ +#!/sbin/openrc-run +# Copyright 1999-2019 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +DAEMON=/usr/bin/lxcfs +PIDFILE=/run/lxcfs.pid + +start() { + ebegin "Starting lxcfs" + + start-stop-daemon --start \ + --pidfile ${PIDFILE} \ + --exec ${DAEMON} \ + --background \ + --make-pidfile \ + -- \ + -o allow_other,nonempty /var/lib/lxcfs + + eend $? +} + +stop() { + ebegin "Stopping lxcfs" + start-stop-daemon --stop --quiet -R TERM/45 -p ${PIDFILE} + eend $? +} diff --git a/sys-fs/lxcfs/lxcfs-3.0.2.ebuild b/sys-fs/lxcfs/lxcfs-3.0.2.ebuild index 6c80f13b0e87..f9c354a881a3 100644 --- a/sys-fs/lxcfs/lxcfs-3.0.2.ebuild +++ b/sys-fs/lxcfs/lxcfs-3.0.2.ebuild @@ -30,7 +30,7 @@ DEPEND=" sys-apps/help2man ${RDEPEND} " -PATCHES="${FILESDIR}/${P}-fusermount-path.patch" +PATCHES="${FILESDIR}/${PN}-fusermount-path.patch" src_prepare() { default @@ -51,7 +51,7 @@ src_configure() { src_install() { default keepdir /var/lib/lxcfs - newinitd "${FILESDIR}"/${P}.initd lxcfs + newinitd "${FILESDIR}"/${PN}.initd lxcfs systemd_dounit config/init/systemd/lxcfs.service } diff --git a/sys-fs/lxcfs/lxcfs-3.0.3.ebuild b/sys-fs/lxcfs/lxcfs-3.0.3.ebuild new file mode 100644 index 000000000000..4d89fb38cc5f --- /dev/null +++ b/sys-fs/lxcfs/lxcfs-3.0.3.ebuild @@ -0,0 +1,72 @@ +# Copyright 1999-2019 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +inherit systemd vcs-snapshot +DESCRIPTION="FUSE filesystem for LXC" +HOMEPAGE="https://linuxcontainers.org/lxcfs/introduction/" +LICENSE="Apache-2.0" +SLOT="0" + +if [[ ${PV} == "9999" ]] ; then + EGIT_REPO_URI="https://github.com/lxc/lxcfs.git" + EGIT_BRANCH="master" + inherit git-r3 + SRC_URI="" + KEYWORDS="" +else + SRC_URI="https://github.com/lxc/lxcfs/archive/${P}.tar.gz" + KEYWORDS="~amd64" +fi + +# Omit all dbus. Upstream appears to require it because systemd, but +# lxcfs makes no direct use of dbus. +RDEPEND=" + dev-libs/glib:2 + sys-fs/fuse:0 +" +DEPEND=" + sys-apps/help2man + ${RDEPEND} +" +PATCHES="${FILESDIR}/${PN}-fusermount-path.patch" + +src_prepare() { + default + ./bootstrap.sh || die "Failed to bootstrap configure files" +} + +src_configure() { + # Without the localstatedir the filesystem isn't mounted correctly + econf --localstatedir=/var +} + +# Test suite fails for me +# src_test() { +# emake tests +# tests/main.sh || die "Tests failed" +# } + +src_install() { + default + keepdir /var/lib/lxcfs + newinitd "${FILESDIR}"/${PN}.initd lxcfs + systemd_dounit config/init/systemd/lxcfs.service +} + +pkg_preinst() { + # In an upgrade situation merging /var/lib/lxcfs (an empty dir) + # fails because that is a live mountpoint when the service is + # running. It's unnecessary anyway so skip the action. + [[ -d ${ROOT}/var/lib/lxcfs ]] && rm -rf ${D}/var +} + +pkg_postinst() { + einfo + einfo "Starting with version 3.0.0 the cgfs PAM module has moved, and" + einfo "will eventually be available in app-emulation/lxc. See:" + einfo "https://brauner.github.io/2018/02/28/lxc-includes-cgroup-pam-module.html" + einfo "for more information." + einfo +} -- cgit v1.2.3-65-gdbad