freebsd-ports/games/minecraft-server/files/minecraft-server
Thomas Zander f0edc641f9 Update to upstream version 1.8.1
PR:		196169
Submitted by:	freebsd@jonathanprice.org (maintainer)
2015-01-01 20:21:35 +00:00

9 lines
237 B
Bash

#!/bin/sh
if [ "$(id -u)" != "0" ]; then
echo "$0 must be run as root" 1>&2
exit 1
fi
cd /usr/local/minecraft-server
su -m mcserver -c "java $(cat /usr/local/etc/minecraft-server/java-args.txt) -jar minecraft_server.1.8.1.jar nogui"