mirror of
https://github.com/SubleXBle/Fail2Ban-Report.git
synced 2026-01-30 21:38:26 -06:00
Create Adding-Clients.md
This commit is contained in:
82
Docs/Adding-Clients.md
Normal file
82
Docs/Adding-Clients.md
Normal file
@@ -0,0 +1,82 @@
|
||||
# Manual Client Installation – Fail2Ban-Report v0.5.0
|
||||
|
||||
## Preparation
|
||||
|
||||
- Check Fail2Ban → must be running
|
||||
- Check UFW → must be running
|
||||
|
||||
## Install required packages
|
||||
|
||||
```
|
||||
apt update -qq && apt install jq gawk curl -y -qq
|
||||
```
|
||||
|
||||
```
|
||||
/opt/Fail2Ban-Report/
|
||||
Backend/
|
||||
Helper-Scripts/
|
||||
archive/
|
||||
fail2ban/
|
||||
blocklists/
|
||||
```
|
||||
|
||||
## Backend scripts
|
||||
|
||||
In /opt/Fail2Ban-Report/Backend/ create the following scripts:
|
||||
|
||||
- fail2ban_log2json.sh ← insert client login credentials
|
||||
- download-checker.sh ← insert client login credentials
|
||||
- firewall-update.sh ← insert client login credentials
|
||||
- syncback.sh ← insert client login credentials
|
||||
|
||||
Make all .sh files executable:
|
||||
|
||||
```
|
||||
chmod +x /opt/Fail2Ban-Report/Backend/*.sh
|
||||
```
|
||||
|
||||
## Helper scripts
|
||||
|
||||
in `/opt/Fail2Ban-Report/Helper-Scripts/` create:
|
||||
|
||||
- `create-client-uuid.sh`
|
||||
|
||||
Make it executable:
|
||||
```
|
||||
chmod +x /opt/Fail2Ban-Report/Helper-Scripts/create-client-uuid.sh
|
||||
```
|
||||
|
||||
Run it once to generate client-uuid.json inside
|
||||
/opt/Fail2Ban-Report/Settings/
|
||||
|
||||
The client UUID will be displayed – copy it.
|
||||
|
||||
|
||||
Optional: Cron jobs
|
||||
|
||||
/path/to/fail2ban_log2json.sh
|
||||
/path/to/download-checker.sh && /path/to/firewall-update.sh && /path/to/syncback.sh
|
||||
|
||||
---
|
||||
|
||||
# On the server
|
||||
|
||||
## Go to Helper-Scripts:
|
||||
|
||||
cd /opt/Fail2Ban-Report/Helper-Scripts/
|
||||
./manage-clients.sh
|
||||
|
||||
Enter data for the new client.
|
||||
|
||||
## WebUI configuration
|
||||
|
||||
Adjust .htaccess as needed
|
||||
|
||||
Add your IP (use Require Any)
|
||||
|
||||
If .htaccess is also used in endpoint/, add IP there as well
|
||||
|
||||
## After first sync of Fail2Ban events
|
||||
|
||||
cd /opt/Fail2Ban-Report/Helper-Scripts/
|
||||
./folder-watchdog.sh
|
||||
Reference in New Issue
Block a user