Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Downloads, installs and configures components required for the MineOS Web User Interface on apt-get based systems using systemd.
#!/bin/sh
# update repositories
curl -sL https://deb.nodesource.com/setup_8.x | bash -
apt-get update
# download the necessary prerequisite components for mineos
apt-get -y install -y nodejs git rdiff-backup screen build-essential openjdk-8-jre-headless
# download the most recent mineos web-ui files from github
mkdir -p /usr/games
cd /usr/games
git clone https://github.com/hexparrot/mineos-node.git minecraft
cd minecraft
git config core.filemode false
chmod +x service.js mineos_console.js generate-sslcert.sh webui.js
ln -s /usr/games/minecraft/mineos_console.js /usr/local/bin/mineos
cp mineos.conf /etc/mineos.conf
npm install --unsafe-perm
# distribute service related files
cp init/systemd_conf /etc/systemd/system/mineos.service
systemctl enable mineos
# generate self-signed certificate
./generate-sslcert.sh
# start the background service
systemctl start mineos
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.