Last active
February 10, 2020 15:45
-
-
Save hexparrot/8831fa43dcf12d3b0ab0 to your computer and use it in GitHub Desktop.
Downloads, installs and configures components required for the MineOS Web User Interface on rpm based systems using systemd.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# update repositories | |
#yum update | |
# download the necessary prerequisite components for mineos | |
curl -sL https://rpm.nodesource.com/setup_10.x | bash - | |
yum -y install screen git wget java-1.8.0-openjdk-headless.x86_64 openssl openssl-devel | |
yum -y groupinstall "Development tools" | |
yum -y install nodejs | |
wget ftp://ftp.pbone.net/mirror/archive.fedoraproject.org/fedora/linux/releases/21/Everything/x86_64/os/Packages/l/librsync-0.9.7-24.fc21.x86_64.rpm | |
wget ftp://ftp.pbone.net/mirror/download.fedora.redhat.com/pub/fedora/linux/releases/25/Everything/x86_64/os/Packages/p/pylibacl-0.5.2-2.fc25.x86_64.rpm | |
wget ftp://ftp.pbone.net/mirror/archive.fedoraproject.org/fedora/linux/releases/19/Everything/x86_64/os/Packages/r/rdiff-backup-1.2.8-9.fc19.x86_64.rpm | |
wget ftp://ftp.pbone.net/mirror/download.fedora.redhat.com/pub/fedora/linux/updates/25/x86_64/Packages/r/rsync-3.1.2-4.fc25.x86_64.rpm | |
rpm -ivh librsync*.rpm | |
rpm -ivh pylibacl*.rpm | |
rpm -ivh rdiff-backup*.rpm | |
rpm -Uvh rsync*.rpm | |
# 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 | |
npm install --all --unsafe-perm | |
ln -s /usr/games/minecraft/mineos_console.js /usr/local/bin/mineos | |
cp mineos.conf /etc/mineos.conf | |
# 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
does not work anymore !