- PHP 8.2 or 8.3
- Nginx, Apache or some other web server software that supports php. Nginx is the favorite here!
- Composer
- Git
- Open the terminal to your web server.
- Execute
cd /var/www/
- Execute
git clone https://github.com/ChimpGamer/NetworkManagerWebbie.git networkmanager
to clone the repository. - Enter the directory by executing
cd networkmanager
- Configure nginx to direct all requests to the ban list application. See Nginx Configuration Example.
- Run the
composer install --optimize-autoloader --no-dev
- Make sure to set the owner of the networkmanager folder to www-data:www-data by executing
sudo chown -R www-data:www-data /var/www/networkmanager
- Rename
.env.example
to.env
by executingmv .env.example .env
. - Configure the settings in the .env file.
- Execute
php artisan key:generate
- You should now be able to browse to networkmanager.example.com (The Server name in your webserver configuration)
To start the user creation process which will create an administrator account, you run:
php artisan nm:create-user
To improve performance there are a few things you can do. Caching! Cache the config, routes and views. You can do this by running these commands:
php artisan config:cache
php artisan route:cache
php artisan view:cache
server {
listen 80;
listen [::]:80;
server_name networkmanager.example.com;
root /var/www/networkmanager/public;
add_header X-Frame-Options "SAMEORIGIN";
add_header X-Content-Type-Options "nosniff";
index index.php;
charset utf-8;
location / {
try_files $uri $uri/ /index.php?$query_string;
}
location = /favicon.ico { access_log off; log_not_found off; }
location = /robots.txt { access_log off; log_not_found off; }
error_page 404 /index.php;
location ~ \.php$ {
fastcgi_pass unix:/var/run/php/php8.3-fpm.sock;
fastcgi_param SCRIPT_FILENAME $realpath_root$fastcgi_script_name;
include fastcgi_params;
}
location ~ /\.(?!well-known).* {
deny all;
}
}
First enter the folder that contains the web files. Then run the following commands to update:
php artisan down
git pull
composer install --no-dev --optimize-autoloader
php artisan optimize:clear
php artisan config:cache
php artisan route:cache
php artisan view:cache
php artisan up
After that it should be running just fine again.
Currently, there is only two addons implemented. Feel free to add more addons by creating a PR.
- UltimateTags - You can enable this addon by running
php artisan module:enable UltimateTags
. The configuration for this addon is located in:addons/UltimateTags/config
. - UltimateJQMessages - You can enable this addon by running
php artisan module:enable UltimateJQMessages
. The configuration for this addon is located in:addons/UltimateJQMessages/config
.