games-server/factorio-server: New ebuild

Package-Manager: Portage-2.3.89, Repoman-2.3.20
Signed-off-by: Alarig Le Lay <alarig@swordarmor.fr>
This commit is contained in:
Alarig Le Lay 2020-04-30 14:01:05 +02:00
parent 010f0aac4c
commit ea018f88ac
Signed by: alarig
GPG Key ID: 7AFE62C6DF8BCDEC
5 changed files with 52 additions and 1 deletions

View File

@ -0,0 +1 @@
DIST factorio-server-0.17.79.tar.xz 32864892 BLAKE2B c583e6c53b08977bf3ddfced5908babd02020ad932ca83fceaab2ef86a15ac62e2755dd9576bdf57dcb79ecc0291ef45772bc824222654c6f73cdcb090e5b928 SHA512 a1201a20914c0c90a91c9a329a4edb15f5904fc4f5b70687204381c9fc5ab157b4dd2a11928ac705de1afd44150f600d8087d6a52e16f9b236a51769d97a9bb6

View File

@ -1,4 +1,4 @@
# Copyright 1999-2019 Gentoo Authors
# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
@ -10,6 +10,13 @@ LICENSE="Factorio"
SLOT="0"
KEYWORDS="~amd64"
DEPENDS="
acct-group/factorio
acct-user/factorio
"
RESTRICT="bindist mirror"
S="${WORKDIR}/factorio"
src_install() {

View File

@ -0,0 +1,4 @@
FACTORIO_PATH="/opt/factorio"
FACTORIO_OPTS="--start-server-load-latest --server-settings ./data/server-settings.json"
FACTORIO_USER="factorio"
FACTORIO_GROUP="factorio"

View File

@ -0,0 +1,24 @@
#!/sbin/openrc-run
# Copyright 2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
name="factorio daemon"
description="2D infinite game"
command="${FACTORIO_PATH}/bin/x64/factorio"
command_args="${factorio_args}"
command_background=1
directory="${FACTORIO_PATH}"
pidfile="/run/${RC_SVCNAME}.pid"
command_user="${FACTORIO_USER:-root}"
command_group="${FACTORIO_GROUP:-root}"
depend() {
need net
}
start_pre() {
checkpath -d -m 0750 -o "${command_user}:${command_group}" \
"${directory}"
}

View File

@ -0,0 +1,15 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="person">
<email>alarig@swordarmor.fr</email>
<name>Alarig Le Lay</name>
</maintainer>
<longdescription>
You will be mining resources, researching technologies, building
infrastructure, automating production and fighting enemies. Use your
imagination to design your factory, combine simple elements into ingenious
structures, apply management skills to keep it working, and protect it from
the creatures who don't really like you.
</longdescription>
</pkgmetadata>