problem description
give an example
version: "2"
services:
portainer:
image: portainer/portainer
command: -H unix:///var/run/docker.sock
restart: always
ports:
- 9000:9000
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- portainer_data:/data
volumes:
portainer_data:
the default volume location called portainer_data
is docker managed (/ var/lib/docker/volumes/portainer_data/_data), so I want to customize a location?
the environmental background of the problems and what methods you have tried
I changed it to,
volumes:
portainer_data:/my_data
this is wrong. Start the error