The automatic setup is fairly straight forward.
Just run those commands as a user that has sudo
permissions:
git clone --recursive https://github.com/lucko/LuckPermsWeb.git
git clone https://github.com/LuckPerms/web-installer.git LuckPermsWeb-installer
cd LuckPermsWeb
../LuckPermsWeb-installer/install.sh
Answer the questions and it will install all missing prerequisites and the editor itself.
Just update the repo and run the install script again:
cd LuckPermsWeb
git reset --hard
git pull
../LuckPermsWeb-installer/install.sh
Run this command:
../LuckPermsWeb-installer/uninstall.sh
There are a few things to watch out for:
- This is designed to use nginx or Apache as the webserver.
- The script will need a dedicated (sub)domain to install LuckPermsWeb to. If you want to install it in a subdir, the script will not work and you have to set it up yourself.
- Automatic package installation only works on Debian-based distros, as
apt-get
is used to install the missing prerequisites. If you're not on Debian-based distro, be sure to have these commands available, then it'll work too:java
(needed for bytebin)jq
nc
nginx
orapache2
netstat
sed
wget
certbot
(only if you want to use HTTPS and want the certificate to be generated by Let's Encrypt)
- The bytebin will be setup using a systemd config. If you are not running on a system that uses systemd, the script will not work and you have to set it up yourself.
Setting up the project manually is simple, you will need some basic knowledge in running a webserver, however. Nginx and Apache are both supported. You also need NodeJS and NPM installed on your system.
Because this repository contains a submodule repository (the LuckPerms wiki) you will want to clone it using the following command:
git clone --recursive https://github.com/lucko/LuckPermsWeb.git
Once it is cloned, move into the new directory and install the dependencies:
cd LuckPermsWeb
npm install
If you are wanting to make changes to the app, you can run a local copy with the following command.
npm run serve
This will automatically open a new tab in your default browser with the app running on a local server. When you make changes to the files, the app will "hot-reload" with the new updates.
If you want to build the project to a folder that can be access via a webserver, running this command will build the project in the /dist
folder:
npm run build
Due to the nature of Vue and how it handles all of the page routing, there are a few things you may need to be aware of:
- The easiest way to host the app is directly under a domain or sub-domain, this requires no extra configuration steps.
- If you do require the app to be hosted under a directory (e.g.
domain.com/luckperms/<here>
) then you will need to edit thebase
property in config.json to match the directory (e.g. change'/'
to'luckperms'
), then run the build command. - You will also need to setup your webserver correctly to redirect any of the pages to the single
index.html
file that is generated under the/dist
folder - some example configrations can be found here. - You can simplify the app and remove certain pages like the downloads and wiki pages by setting
selfHosted
totrue
in config.json. This will also hide the sponsor message in the navigation bar.