mirror of
https://github.com/community-scripts/ProxmoxVE.git
synced 2026-02-03 20:03:25 +01:00
feat(jellyfin): add logrotate instead of reducing log level (#11326)
This commit is contained in:
committed by
GitHub
parent
5a5dd8ae87
commit
25ecb12060
@@ -43,6 +43,10 @@
|
|||||||
{
|
{
|
||||||
"text": "For NVIDIA graphics cards, you'll need to install the same drivers in the container that you did on the host. In the container, run the driver installation script and add the CLI arg --no-kernel-module",
|
"text": "For NVIDIA graphics cards, you'll need to install the same drivers in the container that you did on the host. In the container, run the driver installation script and add the CLI arg --no-kernel-module",
|
||||||
"type": "info"
|
"type": "info"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"text": "Log rotation is configured in /etc/logrotate.d/jellyfin. To reduce verbosity, change MinimumLevel in /etc/jellyfin/logging.json to Warning or Error (disables fail2ban auth logging).",
|
||||||
|
"type": "info"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -39,8 +39,19 @@ EOF
|
|||||||
|
|
||||||
$STD apt update
|
$STD apt update
|
||||||
$STD apt install -y jellyfin
|
$STD apt install -y jellyfin
|
||||||
sed -i 's/"MinimumLevel": "Information"/"MinimumLevel": "Error"/g' /etc/jellyfin/logging.json
|
# Configure log rotation to prevent disk fill (keeps fail2ban compatibility) (PR: #1690 / Issue: #11224)
|
||||||
|
cat <<EOF >/etc/logrotate.d/jellyfin
|
||||||
|
/var/log/jellyfin/*.log {
|
||||||
|
daily
|
||||||
|
rotate 3
|
||||||
|
maxsize 100M
|
||||||
|
missingok
|
||||||
|
notifempty
|
||||||
|
compress
|
||||||
|
delaycompress
|
||||||
|
copytruncate
|
||||||
|
}
|
||||||
|
EOF
|
||||||
chown -R jellyfin:adm /etc/jellyfin
|
chown -R jellyfin:adm /etc/jellyfin
|
||||||
sleep 10
|
sleep 10
|
||||||
systemctl restart jellyfin
|
systemctl restart jellyfin
|
||||||
|
|||||||
Reference in New Issue
Block a user