Logrotate Beispiel nginx: Unterschied zwischen den Versionen

Aus Xinux Wiki
Zur Navigation springen Zur Suche springen
(Die Seite wurde neu angelegt: „ *Die Konfiguration für nginx könnte wie folgt aussehen: <pre> /var/log/nginx/*log { daily missingok rotate 3 notifempty dateext dateformat -%Y-%m-%d…“)
(kein Unterschied)

Version vom 26. März 2025, 19:19 Uhr

  • Die Konfiguration für nginx könnte wie folgt aussehen:
/var/log/nginx/*log {
	daily
	missingok
	rotate 3
	notifempty
	dateext
	dateformat -%Y-%m-%d
	create 640 http log
	compress
	sharedscripts
	postrotate
		test ! -r /run/nginx.pid || kill -USR1 `cat /run/nginx.pid`
	endscript
}