2025-07-16 17:14:16 -06:00

40 lines
937 B
Django/Jinja

version: '3.2'
services:
agent:
image: portainer/agent:lts
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- /var/lib/docker/volumes:/var/lib/docker/volumes
networks:
- agent_network
deploy:
mode: global
placement:
constraints: [node.platform.os == linux]
portainer:
image: portainer/portainer-ce:lts
command: -H tcp://tasks.agent:9001 --tlsskipverify
ports:
- "9443:9443"
- "9000:9000"
- "8000:8000"
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- /docker-shared/stacks/data/portainer:/data
networks:
- agent_network
deploy:
mode: replicated
replicas: {{ item.replicas }}
restart_policy:
condition: {{ item.restart_condition }}
placement:
constraints: [node.role == manager]
privileged: true
networks:
agent_network:
driver: overlay
attachable: true