Files
alpha-quadrant/dev-util/gitea-runner/gitea-runner-3.5.0.ebuild
T

51 lines
1.1 KiB
Bash

# Copyright 2026 migmedia
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit go-module systemd
DESCRIPTION="Official runner for Gitea"
HOMEPAGE="https://gitea.com/gitea/runner"
SRC_URI="
https://gitea.com/gitea/runner/archive/v${PV}.tar.gz -> ${P}.tar.gz
https://gentoo.migmedia.net/alpha-quadrant/${P}-vendor.tar.xz
"
LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64"
DEPEND=""
RDEPEND="${DEPEND}"
BDEPEND="
>=dev-lang/go-1.27.0
"
MY_PN="runner"
S="${WORKDIR}/runner"
src_compile() {
ego build
}
src_prepare() {
sed -i -e 's#/usr/local/bin#/usr/bin#g' examples/systemd/${PN}.service || die "Adjusting systemd.service failed!"
eapply_user
}
src_install() {
newbin runner gitea-runner
dosym -r /usr/bin/gitea-runner /usr/bin/runner
newinitd ${FILESDIR}/initd ${PN}
newconfd ${FILESDIR}/confd ${PN}
systemd_dounit examples/systemd/${PN}.service
dodoc docs/*
dodoc README.md
newdoc examples/systemd/README.md systemd.md
newdoc examples/docker/README.md docker.md
newdoc examples/docker-compose/README.md docker-compose.md
insinto /etc/${PN}
doins internal/pkg/config/config.example.yaml
}