Code Monkey home page Code Monkey logo

Comments (5)

gcgarner avatar gcgarner commented on July 21, 2024

log2ram replaces the /var/log folder with a ramdrive then syncs those changes to disk on a schedule. This reduces the total writes to the sd card.

The containers don't log to /var/log, they log to their own internal logs

from iotstack.

gcgarner avatar gcgarner commented on July 21, 2024

Because each container has its own log that writes to disk inside their respective container it may be worthwhile to map them securely into /var/log to get full benefit of log2ram

from iotstack.

 avatar commented on July 21, 2024

That's what i was asking for, Thanks. I just getting into Docker, may i find out how to map the logs into /var/log

from iotstack.

gcgarner avatar gcgarner commented on July 21, 2024

Each container will differ as to where they store their logs. I used the script "./services/nodered/terminal.sh" to open the shell for nodered. Doing a "ls /var/log" inside nodered shows that its "standard" log is empty. I would assume that the standard log would be empty and containers would do minimal logging.

First you would need to make a subfolder in /var/log that you want to share. Don't directly map your /var/log because you don't want to unnecessarily expose your sensitive data to a container.

If you do find the log for a container you can edit the docker-compose.yml file and under the volumes add

volumes:

  • /var/log/MYLOG:/path/to/log/inside/container

from iotstack.

 avatar commented on July 21, 2024

Thank you!

from iotstack.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.