Update docker-compose.yml to use consistent path for docker.sock volume

This commit is contained in:
2024-05-24 19:30:22 +08:00
parent ed871756b7
commit 4b7deffa9a
2 changed files with 4 additions and 4 deletions
+3 -3
View File
@@ -190,7 +190,7 @@ services:
url: http://kestra.furyhawk.lol/
volumes:
- ./kestra-data:/app/storage
- /${XDG_RUNTIME_DIR}/docker.sock:/var/run/docker.sock
- /var/run/docker.sock:/var/run/docker.sock
- /tmp/kestra-wd:/tmp/kestra-wd
expose:
- "8080"
@@ -375,7 +375,7 @@ services:
container_name: portainer
restart: always
volumes:
- /${XDG_RUNTIME_DIR}/docker.sock:/var/run/docker.sock
- /var/run/docker.sock:/var/run/docker.sock
- portainer_data:/data
networks:
- net
@@ -396,7 +396,7 @@ services:
volumes:
- "${LOG_PATH:-./logs}:/logs"
- production_traefik:/etc/traefik/acme:z
- "/${XDG_RUNTIME_DIR}/docker.sock:/var/run/docker.sock:ro"
- "/var/run/docker.sock:/var/run/docker.sock:ro"
extra_hosts:
- "host.docker.internal:host-gateway"
networks:
+1 -1
View File
@@ -23,4 +23,4 @@ portainer_name=`docker ps | grep portainer-ce | awk '{print $2}'`
sudo docker stop $portainer_pid || error "Failed to stop portainer!"
sudo docker rm $portainer_pid || error "Failed to remove portainer container!"
sudo docker rmi $portainer_name || error "Failed to remove/untag images from the container!"
sudo docker run -d -p 9000:9000 -p 9443:9443 --name=portainer --restart=always -v /${XDG_RUNTIME_DIR}/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer-ce:latest || error "Failed to execute newer version of Portainer!"
sudo docker run -d -p 9000:9000 -p 9443:9443 --name=portainer --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer-ce:latest || error "Failed to execute newer version of Portainer!"