As the title says:
it would be very nice if the logs were moved to a /log sub folder in config.
It’s just more consistent and when using AppDeamon and there are some rotated logfiles it just gets much.
Currently this would include (afaik):
yeh i agree - thought the same too and for the same reasons - in my case using hassio docker. i know it can be done externally but i think it’s better and more consistent through configuration yaml
For anyone else looking to get this working in docker here’s the current solution
With homeassistant docker running run the following command docker exec homeassistant cat /etc/services.d/home-assistant/run
Copy the output into a new file onto your host, edit it and add --log-file=/tmp/hass.log
to the end of the exec python3 line
Then make sure you do chmod +x file_path
Then when running your docker make sure and pass in /file_path:/etc/services.d/home-assistant/run:ro
Annoyingly the fault log path doesnt change but i plan to put in a pr soon to fix that as well as get around having to do all that by using environment variables.
To be honest i forgot i had even done this (I think they changed the location of the file in the first command so i stopped using it)
But yeah this should work with compose, just add the final bit under your volumes: for home assistant
however the location of the file /etc/services.d/home-assistant/run no longer seems valid so it requires finding the new file location, which i do not currently know
I did work on a fix to the code base to allow use of an environment variable set in docker to set the log but i couldnt get a test environment running to test it so was unable to submit it to hass.