From 7066f15c5858c7be840a6fc2683c09781f4fe55e Mon Sep 17 00:00:00 2001 From: Sam James Date: Thu, 4 Mar 2021 05:53:20 +0000 Subject: net-irc/oragono: initial import Signed-off-by: Sam James --- net-irc/oragono/Manifest | 1 + net-irc/oragono/files/oragono.confd | 3 ++ net-irc/oragono/files/oragono.initd | 11 +++++++ net-irc/oragono/metadata.xml | 11 +++++++ net-irc/oragono/oragono-2.5.1.ebuild | 64 ++++++++++++++++++++++++++++++++++++ 5 files changed, 90 insertions(+) create mode 100644 net-irc/oragono/Manifest create mode 100644 net-irc/oragono/files/oragono.confd create mode 100644 net-irc/oragono/files/oragono.initd create mode 100644 net-irc/oragono/metadata.xml create mode 100644 net-irc/oragono/oragono-2.5.1.ebuild (limited to 'net-irc/oragono') diff --git a/net-irc/oragono/Manifest b/net-irc/oragono/Manifest new file mode 100644 index 000000000000..90d1a81846c7 --- /dev/null +++ b/net-irc/oragono/Manifest @@ -0,0 +1 @@ +DIST oragono-2.5.1.tar.gz 3079990 BLAKE2B 0b2c0e330cac974e311ff711b28e7f5cc5548355bcafb14fc903a63e0442e513a890f4ce890c49316603ba1dc7214d8953b3fc62f2aa40fb34e787348900de81 SHA512 684b697a97fb0274e35f8ae491841e5f8c564f778ff19294ff2353e75416e7283295668bff5db57e4950cb991ead5215c501ba1a2c517a12bbbbe85efe983bea diff --git a/net-irc/oragono/files/oragono.confd b/net-irc/oragono/files/oragono.confd new file mode 100644 index 000000000000..3e694bb97038 --- /dev/null +++ b/net-irc/oragono/files/oragono.confd @@ -0,0 +1,3 @@ +# /etc/conf.d/oragono: config file for /etc/init.d/oragono +ORAGONO_CONFIGFILE="/etc/oragono/ircd.yaml" + diff --git a/net-irc/oragono/files/oragono.initd b/net-irc/oragono/files/oragono.initd new file mode 100644 index 000000000000..2379aaea301c --- /dev/null +++ b/net-irc/oragono/files/oragono.initd @@ -0,0 +1,11 @@ +#!/sbin/openrc-run +command=/usr/bin/oragono +command_args="--conf ${ORAGONO_CONFIGFILE:-"/etc/oragono/ircd.yaml"}" +pidfile=/var/run/oraogno.pid +name="Oragono" +description="Oragono IRC daemon" + +depend() { + use dns + provide ircd +} diff --git a/net-irc/oragono/metadata.xml b/net-irc/oragono/metadata.xml new file mode 100644 index 000000000000..d03f63171752 --- /dev/null +++ b/net-irc/oragono/metadata.xml @@ -0,0 +1,11 @@ + + + + + sam@gentoo.org + Sam James + + + oragono/oragono + + diff --git a/net-irc/oragono/oragono-2.5.1.ebuild b/net-irc/oragono/oragono-2.5.1.ebuild new file mode 100644 index 000000000000..6a7fb9b3c975 --- /dev/null +++ b/net-irc/oragono/oragono-2.5.1.ebuild @@ -0,0 +1,64 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit go-module systemd + +DESCRIPTION="A modern IRC server written in Go" +HOMEPAGE="https://oragono.io/ https://github.com/oragono/oragono" +SRC_URI="https://github.com/${PN}/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" +LICENSE="Apache-2.0 BSD-2 BSD ISC MIT MPL-2.0" + +SLOT="0" +KEYWORDS="~amd64" + +BDEPEND=">=dev-lang/go-1.14" +RDEPEND=" + acct-user/oragono + acct-group/oragono +" + +DOCS=( README.md docs/MANUAL.md docs/USERGUIDE.md ) + +src_prepare() { + default + + # Minor fiddling with paths + sed -i \ + -e 's:/home/oragono/oragono:/usr/bin/oragono:' \ + -e 's:/home/oragono:/var/lib/oragono:' \ + -e 's:/var/lib/oragono/ircd.yaml:/etc/oragono/ircd.yaml:' \ + distrib/systemd/oragono.service || die +} + +src_compile() { + go build -mod=vendor . || die +} + +src_install() { + einstalldocs + + dobin oragono + + insinto /etc/oragono + doins default.yaml + + newinitd "${FILESDIR}"/oragono.initd oragono + newconfd "${FILESDIR}"/oragono.confd oragono + + keepdir /var/lib/oragono + fowners oragono:oragono /var/lib/oragono + + insinto /var/lib/oragono + doins -r languages/ + + systemd_dounit distrib/systemd/oragono.service +} + +pkg_postinst() { + if [[ -z "${REPLACING_VERSIONS}" ]] ; then + elog "Please copy the example config in ${EROOT}/etc/oragono:" + elog "e.g. cp ${EROOT}/etc/oragono/default.yaml ${EROOT}/etc/oragono/ircd.yaml" + fi +} -- cgit v1.2.3-65-gdbad