Giter Site home page Giter Site logo

docker-logrotate's People

Contributors

ferdinandhuebner avatar freol35241 avatar msiegenthaler avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

docker-logrotate's Issues

Custom logrotate expression (`LOGROTATE_CRON`) gets executed multiple times

Hi,

Thanks for putting together this, very convenient and I find myself using it from time to time.

However, I have been running into a problem where a custom cron expression (i.e using LOGROTATE_CRON) gets executed multiple times and digging in to this I found /var/spool/cron/crontabs/root looking like this:

# do daily/weekly/monthly maintenance
# min   hour    day     month   weekday command
*/15    *       *       *       *       run-parts /etc/periodic/15min
0       *       *       *       *       run-parts /etc/periodic/hourly
0       2       *       *       *       run-parts /etc/periodic/daily
0       3       *       *       6       run-parts /etc/periodic/weekly
0       5       1       *       *       run-parts /etc/periodic/monthly

0 0 * * * /etc/.logrotate.cronjob
0 0 * * * /etc/.logrotate.cronjob
0 0 * * * /etc/.logrotate.cronjob
0 0 * * * /etc/.logrotate.cronjob

I.e. it as multiple identical lines appended to the bottom. Currently, my best guess is that this Confirmed, this is a result of restarts of the container (which do preserve the filesystem I think?) in combination with appending instead of overwriting in https://github.com/linkyard/docker-logrotate/blob/master/entrypoint.sh#L25.

Will try to find some time to try out a fix and revert with a PR if it works out.

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.