[Unit] Description=Draggable Docker Desktop Dashboard Manager After=docker.service registry.service StartLimitIntervalSec=0 [Service] Restart=always # Remove any previous instance of the container ExecStartPre=-/usr/bin/docker stop docker-manager ExecStartPre=-/usr/bin/docker rm -f docker-manager # Ensure the infrastructure network exists, ignoring errors if it already does ExecStartPre=/bin/sh -c '/usr/bin/docker network create entertainment || true' # Pull the image ExecStartPre=/bin/sh -c 'until /usr/bin/docker pull localhost:5000/docker-manager:latest; do echo "Pulling image..."; sleep 5; done' # Run the derived container instance ExecStart=/usr/bin/docker run \ --name=docker-manager \ --rm \ --hostname docker-manager \ --net=entertainment \ --publish 3000:3000 \ --pids-limit=50 \ --volume /var/run/docker.sock:/var/run/docker.sock \ --volume /mnt/docker-applications/docker-manager:/usr/src/app/data \ --label traefik.http.services.docker-manager.loadbalancer.server.port=3000 \ localhost:5000/docker-manager:latest ExecStop=/usr/bin/docker stop docker-manager ExecStop=/usr/bin/docker rm -f docker-manager TimeoutSec=300 [Install] WantedBy=multi-user.target