Jump to content

Docker: Pipe output of Emby Server to Docker Logs


Recommended Posts

sydlexius
Posted (edited)

I searched and didn't find anything, so I thought I'd request a modification to your docker logs to continue outputting after the "All entry points have started" message?  Ideally, this could be governed by an environmental variable for those who don't want to worry about their docker logs directory getting blown up.  To be clear, I want to see output from Emby Server logging when I run something like docker logs EmbyServer -f.

Edited by sydlexius
  • Like 6
Posted

Hi, yes I suppose an option for this is reasonable.

sydlexius
Posted
20 minutes ago, Luke said:

Hi, yes I suppose an option for this is reasonable.

I know there are probably a few ways, but based on what little research I've done, you could have an environmental variable like OutputLogsToDocker set to 1, and have an additional service called /etc/services.d/emby-logger, where its run script might look like this:

 

#!/usr/bin/with-contenv sh
# Check if OutputLogsToDocker is set to 1
if [ "${OutputLogsToDocker}" = "1" ]; then
    # Tail the log file and output to stdout
    exec tail -F /config/logs/logfiles.txt
else
    # Do not tail the log file; just sleep indefinitely
    # This keeps the service running without doing anything
    exec sleep infinity
fi

 

  • 7 months later...
Posted

yup, my dozzle also only these logs, and make it no easy to see what to the spot embyserver facing problem.

  • 2 months later...
AshranPewter
Posted

Ya this would be nice, getting the logs to somewhere else to view becomes a bit of a chore whereas with docker I can just pipe them somewhere easily. Would be really nice to have this.

  • 9 months later...
Posted

Sorry for the necromancy - but i found this looking for the same thing.

Didnt find anything so modifed the container image to output more to stdout: 

https://github.com/matty87a/emby-stdout

 

You can control which logs make it to stdout with an env in your docker setup (default below)

EMBY_LOGS =embyserver,ffmpeg,hardware  
  • Like 2

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...