# docker-compose file to start up watchtower, docker container auto updating service
# to start the container run:
# docker-compose up -d
#
# Note2: docker container name is sourced from the .env file in this directory.
#
# Note3: containrrr/watchtower service will auto update this container
name: watchtower-localhost
services:
watchtower:
image: containrrr/watchtower
container_name: watchtower.localhost
restart: always
mem_limit: 64M
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- /etc/localtime:/etc/localtime:ro
labels:
- com.centurylinklabs.watchtower.enable=true
# Update containers at 4.15am and delete old images after update
command: --label-enable --cleanup --schedule "0 15 4 * * *"