diff --git a/.drone-home.star b/.drone-home.star new file mode 100644 index 0000000..dec987c --- /dev/null +++ b/.drone-home.star @@ -0,0 +1,14 @@ + +load("@this//portainer:drone.star", "drone") +load("@this//portainer:stack-name.star", "stackName") +load("@this//portainer:stack-root.star", "stackRoot") + +def main(ctx): + return drone( + ctx, + "home-deploy", + stackRoot, + stackName, + [] + ) + \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..ecb3504 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,46 @@ +version: "3.7" +services: + portainer: + image: portainer/portainer:1.23.2 + command: -H tcp://tasks.portainer-agent:9001 --tlsskipverify + # command: -H unix:///var/run/docker.sock + deploy: + replicas: 1 + placement: + constraints: [node.role == manager] + restart_policy: + condition: any + volumes: + - /var/run/docker.sock:/var/run/docker.sock + - portainer-data:/data + networks: + #- proxy + - appnet + - externalnet + portainer-agent: + image: portainer/agent:1.5.1 + environment: + # REQUIRED: Should be equal to the service name prefixed by "tasks." when + # deployed inside an overlay network + AGENT_CLUSTER_ADDR: tasks.portainer-agent + # AGENT_PORT: 9001 + # LOG_LEVEL: debug + volumes: + - /var/run/docker.sock:/var/run/docker.sock + - /var/lib/docker/volumes:/var/lib/docker/volumes + networks: + - appnet + deploy: + mode: global + placement: + constraints: [node.platform.os == linux] +volumes: + portainer-data: + +networks: + appnet: + driver: overlay + #external: true + externalnet: + driver: overlay + external: true