monicahq / docker

docker image of Monica
https://hub.docker.com/_/monica/
GNU General Public License v2.0
203 stars 61 forks source link

Log files created with wrong permissions under some cases #105

Closed chmac closed 1 year ago

chmac commented 2 years ago

(Note: you don't need to follow this template, nor to keep headlines or bold sentences - they are just there to guide you. Feel free to delete everything. We review every issue even if we don't immediately respond.)

Thanks for filing an issue and for your interest in the project.

Describe the bug When running a command from the console (inside docker), if this command generates the first error of the day, a logfile will be created in logs/ with today's date. It's owned by root:www-admin but its permissions are -rw-r--r-- and so the apache process cannot write to the logfile.

Which version are you using: I'm running monica 3.6.1 in the monica:apache docker image.

Steps to reproduce

asbiin commented 1 year ago

For docker, it's recommended to use stderr as a logger, so you can have logs in docker logs command.

asbiin commented 1 year ago

Use the LOG_CHANNEL=stderr environment variable to handle logs in docker