userlogrotate: rotate also php.log

This commit is contained in:
William Hirigoyen 2023-04-27 10:52:32 +02:00
parent 5c60fad29c
commit 9821fc8f78
2 changed files with 3 additions and 2 deletions

View file

@ -12,6 +12,7 @@ The **patch** part changes is incremented if multiple releases happen the same m
## [Unreleased]
### Added
* userlogrotate: rotate also php.log.
### Changed
* evolinux-users: remove Stretch references in tasks that also apply to next Debian versions.

View file

@ -15,7 +15,7 @@ user_for() {
stat -L -c '%G' $homedir
}
for log in access.log access-*.log error.log; do
for log in access.log access-*.log error.log php.log; do
for i in $(ls -1 -d $HOMEPREFIX/*/log/$log 2>/dev/null | grep -v \.bak\.); do
USER="$(user_for $i)"
rotate $i root:$USER
@ -55,4 +55,4 @@ for log in production.log*[!\.gz] delayed_job.log*[!\.gz] development.log*[!\.gz
done
done
exit 0
exit 0