Merge pull request #1255 from jc21/fixes-crash-when-logrotation-fails
This commit is contained in:
commit
6f3a00c9b8
@ -210,8 +210,10 @@ const setupLogrotation = () => {
|
||||
const intervalTimeout = 1000 * 60 * 60 * 24 * 2; // 2 days
|
||||
|
||||
const runLogrotate = async () => {
|
||||
await utils.exec('logrotate /etc/logrotate.d/nginx-proxy-manager');
|
||||
logger.info('Logrotate completed.');
|
||||
try {
|
||||
await utils.exec('logrotate /etc/logrotate.d/nginx-proxy-manager');
|
||||
logger.info('Logrotate completed.');
|
||||
} catch (e) { logger.warn(e); }
|
||||
};
|
||||
|
||||
logger.info('Logrotate Timer initialized');
|
||||
|
4
docker/rootfs/etc/cont-init.d/01_perms.sh
Executable file
4
docker/rootfs/etc/cont-init.d/01_perms.sh
Executable file
@ -0,0 +1,4 @@
|
||||
#!/usr/bin/with-contenv bash
|
||||
|
||||
mkdir -p /data/logs
|
||||
chown -R root:root /data/logs
|
Loading…
Reference in New Issue
Block a user