ampache / ampache-docker

Ampache docker package
http://ampache.org
93 stars 68 forks source link

get errors if debug is enabled #62

Open grisumaniac opened 3 years ago

grisumaniac commented 3 years ago

I have version 4.4.2 running, but having problems to stream to an ios subsonic-client. (avsub, get music data and pictures but when i hit play nothing happens) To check this problem, i have set debug = "true" in the config, but then i get errors "unable to write to log..." because the default path in the config is set to /var/log/ampache but there is no such path in the container !

I have checked the Dockerfile and in particular the file docker_entrypoint.sh:

...
if [ "$1" = '/run.sh' ] && [ "$(id -u)" = '0' ]; then
    mkdir -p /var/logs/ampache
    chown -R www-data:www-data /var/www/config /var/logs/ampache
    exec gosu www-data "$@"
else
  exec "$@"
fi

The path /var/logs doesnt exist, the correct path should be /var/log/ampache, or am i wrong?

Please help

lachlan-00 commented 3 years ago

/var/log

lachlan-00 commented 3 years ago

going to rebuild all the images again soon and they've all been updated now

grisumaniac commented 3 years ago

Testing version 4.4.3-nosql: Path /var/log/ampache in docker-entrypoint.sh is now correct but after fresh start of the container, no /var/log/ampache is created.

If i do the following manually, debug works: mkdir /var/log/ampache chown -R www-data:www-data /var/log/ampache

Am i doing something wrong?

lachlan-00 commented 3 years ago

The dir should get made by the build. I'll Look at why it's missing and do a rebuild

lachlan-00 commented 3 years ago

i've changed the build process to create the dir during container build instead of from the entrypoint.

building new images now so this should fix it