Skip to content
This repository has been archived by the owner on Jan 7, 2024. It is now read-only.

Add Unifi server.log to logrotate config #144

Closed
JagerSprinkles opened this issue May 23, 2022 · 4 comments
Closed

Add Unifi server.log to logrotate config #144

JagerSprinkles opened this issue May 23, 2022 · 4 comments
Labels
work-in-progress Stale exempt

Comments

@JagerSprinkles
Copy link

linuxserver.io


Desired Behavior

I do not see logrotate being configured for '/usr/lib/unifi/logs/server.log' only for '/usr/lib/unifi/logs/mongod.log' I have checked all the files in /etc/logrotate.d/

Contents of /etc/logrotate.d/unifi

root@unifi-controller:/usr/lib/unifi# cat /etc/logrotate.d/unifi
/usr/lib/unifi/logs/mongod.log {
        rotate 5
        size 50M
        compress
        missingok
        sharedscripts
        su unifi unifi
        postrotate
                test ! -r /usr/lib/unifi/run/mongod.pid || kill -USR1 $(cat /usr/lib/unifi/run/mongod.pid)
        endscript
}

Current Behavior

/usr/lib/unifi/logs/server.log is not rotated

Alternatives Considered

I considered making my own container based off of this one but maintaining a container just to make sure the logs don't run away is a bit much.

I hope that maintaining the log size is in the scope for this container. (Also 50MB might be a little high for these logs)

@github-actions
Copy link

Thanks for opening your first issue here! Be sure to follow the bug or feature issue templates!

@github-actions
Copy link

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@fermulator
Copy link
Contributor

@github-actions bot go away (this is a value enhancement request)

@bmatheny
Copy link

bmatheny commented Dec 1, 2022

@j0nnymoe is this something you are working on? I'd also like it. For whoever does work on it, the existing logrotate config doesn't come from docker-unifi-controller it comes from the mongo package. Since this image doesn't right now really do any configuration stuff besides system.properties, whoever puts together the PR for this would need to pull in the scaffolding to distribute configs. I think the linuxserver team has some of this already, but just a heads up.

@thespad thespad closed this as not planned Won't fix, can't repro, duplicate, stale Jan 7, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
work-in-progress Stale exempt
Projects
Archived in project
Development

No branches or pull requests

5 participants