version: "3" services: portainer: container_name: portainer image: portainer/portainer-ce:latest ports: - 9443:9443 env_file: - .env volumes: - ${PORTAINER_DATA}:/data - /var/run/docker.sock:/var/run/docker.sock restart: unless-stopped volumes: data: