From ea01855001911417edd0b25942eedaf5239a2a35 Mon Sep 17 00:00:00 2001 From: Marcel <110860055+Morethanevil@users.noreply.github.com> Date: Sat, 7 Jun 2025 19:42:16 +0200 Subject: [PATCH] Updated FAQ Frequently Asked Questions (markdown) --- FAQ---Frequently-Asked-Questions.md | 50 ++++++++++++++++++++++++++--- 1 file changed, 45 insertions(+), 5 deletions(-) diff --git a/FAQ---Frequently-Asked-Questions.md b/FAQ---Frequently-Asked-Questions.md index 02839f9..3d44f05 100644 --- a/FAQ---Frequently-Asked-Questions.md +++ b/FAQ---Frequently-Asked-Questions.md @@ -43,18 +43,22 @@ Put in following lines: ``` [Unit] -Description=Zoraxy Service -After=network.target +Description=Zoraxy Reverse Proxy Server +After=network-online.target +Wants=network-online.target [Service] Type=simple +# root is needed here, since Zoraxy uses ports < 1000 and doing network stuff + User=root Group=root -WorkingDirectory=/opt/zoraxy/src -ExecStart=/opt/zoraxy/src/zoraxy -port=:8000 -Restart=always +# Change the paths according to your needs! + +WorkingDirectory=/directory/containing/zoraxy +ExecStart=/path/to/zoraxy_linux_amd64 -port=:8400 -fastgeoip=true [Install] WantedBy=multi-user.target @@ -68,3 +72,39 @@ Now status messages can be showed with: `sudo systemctl status zoraxy` Source: [https://github.com/tobychui/zoraxy/issues/8](https://github.com/tobychui/zoraxy/issues/8) + +# Logrotation +Zoraxy logs can become big, depending on the usage and traffic. + +Let´s create a logrotation rule for it! + +`sudo nano /etc/logrotate.d/zoraxy` + +Change the path to the directory containing Zoraxy logs (full path) + +```plain +/path/to/the/zoraxy/log/*.log { + daily + missingok + rotate 7 + compress + delaycompress + notifempty +} +``` + +"daily" means daily execution + +"missingok" ignore if no log files existing + +"rotate 7" keep old log files for 7 days + +"compress" compress log files (log.gz) + +"delaycompress" waits a little bit before compressing the first file to avoid data loss + +"notifempty" ignores empty files + +Run and test with: + +`sudo logrotate -d /etc/logrotate.d/zoraxy` \ No newline at end of file