I have several containers running on my Raspberry Pi 3 that I’d like to aggregate the logs for and stream them using Papertrail. It seems that the generally accepted method to do this is have a dedicated logging container that aggregates the other containers log events. This can be done in docker using some version of this in the docker-compose:
logspout: image: gliderlabs/logspout:latest command: 'syslog://logsN.papertrailapp.com:XXXXX ' volumes: - '/var/run/docker.sock:/tmp/docker.sock'
After exploring the Host on Balena OS, and a few forum posts, it seems that
/var/run/docker.sock. Given that bind mounts are not supported by Balena, I’m at a bit of a loss as to what to do. This forum post ( Where is docker.sock? ) is the closest I’ve come to finding a similar issue, however because I’m building directly from an image, I don’t have the option of using
CP inside the docker file.
How do I connected to the Docker (Balena) socket if bind mounts aren’t supported. Otherwise, is there a generally accepted way to aggregate logs from multiple containers?