version: '3.8'

services:
  newt:
    image: fosrl/newt:latest
    deploy:
      replicas: 1
      placement:
        constraints:
          # Run on Manager (HP Mini) for network stability
          - node.role == manager
      restart_policy:
        condition: on-failure
    environment:
      - PANGOLIN_ENDPOINT=https://proxy.prestonhunter.space
      - NEWT_ID=tj28dyjct79m75g
      - NEWT_SECRET=ba8vvi9gqmi21o6f2d8hp4rjdag7qwm2fjpfkobivv44qng5
    networks:
      - proxy

networks:
  proxy:
    external: true