forked from tastytea/overlay
www-apps/gitea: Handle file capabilities properly
Package-Manager: Portage-2.3.49, Repoman-2.3.11 Manifest-Sign-Key: 3555266864CA6D7FF45AA6E7CFC39497F1B26E07
This commit is contained in:
parent
2993abf483
commit
440660ee09
|
@ -14,12 +14,13 @@ DIST gitea-1.5.2.tar.gz 18866286 BLAKE2B a9a31fa6a310dcb6debd9399f234262214021d7
|
||||||
EBUILD gitea-1.5.0-r1.ebuild 2065 BLAKE2B 34663fba254d112ba773fdcf3ffcfb5e2fbe2950e448cb2126b436d376a0d86a68a214c8f3e7e1f02548b649b1415aa1abec93b0ca8b6d1ae44e88f8a903a51a SHA512 aa4d6fbc428ae753c1311254cc396d4298ef39b1cdc29445474874bca3479efb3e09917514615c430103eb13d947547eb44c0b7a30503c109fed335baec9107a
|
EBUILD gitea-1.5.0-r1.ebuild 2065 BLAKE2B 34663fba254d112ba773fdcf3ffcfb5e2fbe2950e448cb2126b436d376a0d86a68a214c8f3e7e1f02548b649b1415aa1abec93b0ca8b6d1ae44e88f8a903a51a SHA512 aa4d6fbc428ae753c1311254cc396d4298ef39b1cdc29445474874bca3479efb3e09917514615c430103eb13d947547eb44c0b7a30503c109fed335baec9107a
|
||||||
EBUILD gitea-1.5.0.ebuild 1896 BLAKE2B 026de80a45a7c8460a337074552348a008168329a6004095e35b2ff61de4b10c77131f35b3b6c471975c8bd80826cd9aa261ad914130eb8133446a335bc2211d SHA512 79523a1d09df95268a462c3a210e71ee4a1c485aa290af5d4d38c163f95400681b207fe6c3bab7c9985c6371f73be4779f4ccaa52db2ec60a3a0c7ebc1ec3362
|
EBUILD gitea-1.5.0.ebuild 1896 BLAKE2B 026de80a45a7c8460a337074552348a008168329a6004095e35b2ff61de4b10c77131f35b3b6c471975c8bd80826cd9aa261ad914130eb8133446a335bc2211d SHA512 79523a1d09df95268a462c3a210e71ee4a1c485aa290af5d4d38c163f95400681b207fe6c3bab7c9985c6371f73be4779f4ccaa52db2ec60a3a0c7ebc1ec3362
|
||||||
EBUILD gitea-1.5.1-r1.ebuild 2062 BLAKE2B 42bdae8b8adcfadb97d87c6674a8f58c1978af83c4dc2e5df47d355c4d9cac6bc25437b58238fac8644bf1dcf97442ddeebf623de43c7d0556b37280c4f1bd32 SHA512 e9160aa0e3aca093dd438d046885ac1583a80467f1ff3aaad733a9011417e38296cc15082ebdf3ff0bb56eb256d82deb2d69552f947cc72ad8ff188175c3652b
|
EBUILD gitea-1.5.1-r1.ebuild 2062 BLAKE2B 42bdae8b8adcfadb97d87c6674a8f58c1978af83c4dc2e5df47d355c4d9cac6bc25437b58238fac8644bf1dcf97442ddeebf623de43c7d0556b37280c4f1bd32 SHA512 e9160aa0e3aca093dd438d046885ac1583a80467f1ff3aaad733a9011417e38296cc15082ebdf3ff0bb56eb256d82deb2d69552f947cc72ad8ff188175c3652b
|
||||||
|
EBUILD gitea-1.5.2-r1.ebuild 2005 BLAKE2B c5a7d1d2093bdc7cf2abc23a35076488d530752993419df87ce6dd6af8b61a01a1274720d77d3ded36e12e6e7b2764de1cef7063e0aeac8b109fb7bb6b1f6d28 SHA512 7a66b0a68364c28ae524d8f0e234c502ea1479d3e118d71b7020002777b4d084a778e20809c9860a7695d61aa6826d9aed235e164a970d338ec873de83ada152
|
||||||
EBUILD gitea-1.5.2.ebuild 2062 BLAKE2B 42bdae8b8adcfadb97d87c6674a8f58c1978af83c4dc2e5df47d355c4d9cac6bc25437b58238fac8644bf1dcf97442ddeebf623de43c7d0556b37280c4f1bd32 SHA512 e9160aa0e3aca093dd438d046885ac1583a80467f1ff3aaad733a9011417e38296cc15082ebdf3ff0bb56eb256d82deb2d69552f947cc72ad8ff188175c3652b
|
EBUILD gitea-1.5.2.ebuild 2062 BLAKE2B 42bdae8b8adcfadb97d87c6674a8f58c1978af83c4dc2e5df47d355c4d9cac6bc25437b58238fac8644bf1dcf97442ddeebf623de43c7d0556b37280c4f1bd32 SHA512 e9160aa0e3aca093dd438d046885ac1583a80467f1ff3aaad733a9011417e38296cc15082ebdf3ff0bb56eb256d82deb2d69552f947cc72ad8ff188175c3652b
|
||||||
MISC metadata.xml 363 BLAKE2B ab235f6b884680f4d064cae732d35c801a22621f6198fa5ac602cd97a479c1799105605449f1f36319646db463daa1399d94c122e73ef2ebd6045efd0a94e990 SHA512 64ff18a1d82b7774385df7708b4bf6201e2508c961cb1fa2dc4de2a8a0fc477a0d388782dbbf50befa7f4787f5d5fb6a986a4631009cf8dcebe4c83f17405865
|
MISC metadata.xml 363 BLAKE2B ab235f6b884680f4d064cae732d35c801a22621f6198fa5ac602cd97a479c1799105605449f1f36319646db463daa1399d94c122e73ef2ebd6045efd0a94e990 SHA512 64ff18a1d82b7774385df7708b4bf6201e2508c961cb1fa2dc4de2a8a0fc477a0d388782dbbf50befa7f4787f5d5fb6a986a4631009cf8dcebe4c83f17405865
|
||||||
-----BEGIN PGP SIGNATURE-----
|
-----BEGIN PGP SIGNATURE-----
|
||||||
|
|
||||||
iHUEAREIAB0WIQQ1VSZoZMptf/RapufPw5SX8bJuBwUCW7zbhQAKCRDPw5SX8bJu
|
iHUEAREIAB0WIQQ1VSZoZMptf/RapufPw5SX8bJuBwUCW9la8wAKCRDPw5SX8bJu
|
||||||
B4gVAP4zhySzUGRfXSzlhbk3sY46jwxIhZ1r1oEJZibrdhicQAD/aP4UdflKTohG
|
B/6oAP9tjS29zUtLLuqP7ZxrPfWOkbY7DEOechTT8G4vx2PbpwD/YRRR/KpXiOwc
|
||||||
yK2VKcfE05knSyPb9WUve2obnaaIRgo=
|
eH4HVB8PAIMqbnrNPzfjVehbzPfiAtQ=
|
||||||
=61ay
|
=YFmV
|
||||||
-----END PGP SIGNATURE-----
|
-----END PGP SIGNATURE-----
|
||||||
|
|
69
www-apps/gitea/gitea-1.5.2-r1.ebuild
Normal file
69
www-apps/gitea/gitea-1.5.2-r1.ebuild
Normal file
|
@ -0,0 +1,69 @@
|
||||||
|
# Copyright 1999-2018 Gentoo Authors
|
||||||
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
|
EAPI=6
|
||||||
|
inherit user systemd golang-build golang-vcs-snapshot fcaps
|
||||||
|
|
||||||
|
EGO_PN="code.gitea.io/gitea"
|
||||||
|
KEYWORDS="~amd64 ~arm"
|
||||||
|
|
||||||
|
DESCRIPTION="A painless self-hosted Git service, written in Go"
|
||||||
|
HOMEPAGE="https://gitea.io/"
|
||||||
|
SRC_URI="https://github.com/go-gitea/gitea/archive/v${PV/_/-}.tar.gz -> ${P}.tar.gz"
|
||||||
|
|
||||||
|
LICENSE="MIT"
|
||||||
|
SLOT="0"
|
||||||
|
|
||||||
|
DEPEND="
|
||||||
|
dev-go/go-bindata
|
||||||
|
sys-libs/pam
|
||||||
|
"
|
||||||
|
RDEPEND="
|
||||||
|
dev-vcs/git[curl,threads]
|
||||||
|
sys-libs/pam
|
||||||
|
"
|
||||||
|
|
||||||
|
FILECAPS=( cap_net_bind_service+ep usr/bin/gitea )
|
||||||
|
|
||||||
|
pkg_setup() {
|
||||||
|
enewgroup git
|
||||||
|
enewuser git -1 /bin/bash /var/lib/gitea git
|
||||||
|
}
|
||||||
|
|
||||||
|
src_prepare() {
|
||||||
|
default
|
||||||
|
sed -i -e "s/\"main.Version.*$/\"main.Version=${PV}\"/"\
|
||||||
|
-e "s/-ldflags '-s/-ldflags '/" src/${EGO_PN}/Makefile || die
|
||||||
|
}
|
||||||
|
|
||||||
|
src_compile() {
|
||||||
|
GOPATH="${WORKDIR}/${P}:$(get_golibdir_gopath)" emake -C src/${EGO_PN} generate
|
||||||
|
TAGS="bindata pam sqlite" LDFLAGS="" CGO_LDFLAGS="" GOPATH="${WORKDIR}/${P}:$(get_golibdir_gopath)" emake -C src/${EGO_PN} build
|
||||||
|
}
|
||||||
|
|
||||||
|
src_install() {
|
||||||
|
diropts -m0750 -o git -g git
|
||||||
|
keepdir /var/log/gitea /var/lib/gitea /var/lib/gitea/data
|
||||||
|
pushd src/${EGO_PN} || die
|
||||||
|
dobin gitea
|
||||||
|
insinto /var/lib/gitea/conf
|
||||||
|
newins custom/conf/app.ini.sample app.ini.example
|
||||||
|
popd || die
|
||||||
|
newinitd "${FILESDIR}"/gitea.initd-r2 gitea
|
||||||
|
newconfd "${FILESDIR}"/gitea.confd gitea
|
||||||
|
keepdir /var/log/gitea /var/lib/gitea/data
|
||||||
|
systemd_dounit "${FILESDIR}/gitea.service"
|
||||||
|
}
|
||||||
|
|
||||||
|
pkg_postinst() {
|
||||||
|
if [[ ! -e "${EROOT}/var/lib/gitea/conf/app.ini" ]]; then
|
||||||
|
elog "No app.ini found, copying initial config over"
|
||||||
|
cp "${FILESDIR}"/app.ini "${EROOT}"/var/lib/gitea/conf/ || die
|
||||||
|
chown git:git /var/lib/gitea/conf/app.ini
|
||||||
|
else
|
||||||
|
elog "app.ini found, please check example file for possible changes"
|
||||||
|
ewarn "Please note that environment variables have been changed:"
|
||||||
|
ewarn "GITEA_WORK_DIR is set to /var/lib/gitea (previous value: unset)"
|
||||||
|
ewarn "GITEA_CUSTOM is set to '\$GITEA_WORK_DIR/custom' (previous: /var/lib/gitea)"
|
||||||
|
fi
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user