From 0136d44a2c771066d4f28eeb641765d9f699ea34 Mon Sep 17 00:00:00 2001 From: Dirk Hohndel Date: Mon, 2 Oct 2023 16:33:07 -0700 Subject: [PATCH] don't run docker prune when installed as app Signed-off-by: Dirk Hohndel --- .../filesystem/root/opt/adsb/docker-update-adsb-im | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/modules/adsb-feeder/filesystem/root/opt/adsb/docker-update-adsb-im b/src/modules/adsb-feeder/filesystem/root/opt/adsb/docker-update-adsb-im index 939e2bcb..d32268cd 100755 --- a/src/modules/adsb-feeder/filesystem/root/opt/adsb/docker-update-adsb-im +++ b/src/modules/adsb-feeder/filesystem/root/opt/adsb/docker-update-adsb-im @@ -39,8 +39,9 @@ echo "${TIME}: pulling new container images and restarting docker" >> /var/log/a bash ./docker-pull.sh bash /opt/adsb/docker-compose-start -# finally remove the images and files we no longer use -docker system prune -f +# finally remove the images and files we no longer use - but only if this is the image we are running +# this would be rude to do on a system where we are one of many apps potentially using docker. +[ -f os.adsb.feeder.image ] && docker system prune -f sed -i "s/CONTAINER_VERSION=.*/CONTAINER_VERSION=$TIME/" /opt/adsb/config/.env