service, readme

This commit is contained in:
root 2025-02-22 22:42:37 +01:00
parent 7807157052
commit 115d0bc752
2 changed files with 40 additions and 0 deletions

22
README.md Normal file
View File

@ -0,0 +1,22 @@
# RouterOS backup system
1. Instalation:
- clone (to ex. /opt/routeros_backup)
- create venv
- install requirements via pip
- copy systemd service (routeros_backup.service)
2. Start
- systemctl start routeros_backup.service
- go to http://<IP>:81
3. Register, Login
4. Configure devices, keys, backups
5. Done
## Authors
- [@linuxiarz.pl]

18
routeros_backup.service Normal file
View File

@ -0,0 +1,18 @@
[Unit]
Description=RouterOS Backup Application
After=network.target
[Service]
#User=www-data # Zmień na odpowiedniego użytkownika
#Group=www-data
WorkingDirectory=/opt/routeros_backup
Environment="PATH=/opt/hosts_app/venv/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
Environment="FLASK_APP=app.py"
Environment="FLASK_ENV=production"
ExecStart=/opt/routeros_backup/venv/bin/gunicorn -c /opt/routeros_backup/gunicorn_config.py --worker-class gevent --keep-alive 10 app:app
Restart=always
RestartSec=5
[Install]
WantedBy=multi-user.target