kerberos-io / kerberos-docker

Run Kerberos Open Source inside a docker container.
http://doc.kerberos.io/opensource/installation#docker
103 stars 31 forks source link

Have an option to disable internal cleanup #35

Open sergeolkhovik opened 3 years ago

sergeolkhovik commented 3 years ago

I've 4 cameras served by 4 instances of kerberos-docker (each writes into own sub-folder, i.e. /var/lib/kerberos.io/camX), and I noticed that some cameras have very less videos in the storage folder. I assume the reason is that I have 4 autoremoval instances running at the same time and depending on system load some may clean more files in its camera storage than others? Is it possible to disable autoremoval code by, for example, checking for .noautoremoval file in this run.sh script? Something like this:

[ -e /etc/opt/kerberosio/capture/.noautoremoval ] || autoremoval &

? And then I'll write own script that will walk over all storages and do a clean-up, via cron or systemd timers.