# Run the Synapse-iDOCK agent on a host with:  docker compose up -d
# Set IDOCK_URL / IDOCK_TOKEN below (or in a .env file next to this one).
services:
  idock-agent:
    image: ${IDOCK_AGENT_IMAGE:-synapse-idock-agent:1.0.0}
    container_name: idock-agent
    restart: unless-stopped
    environment:
      IDOCK_URL: ${IDOCK_URL:?set IDOCK_URL to your Synapse-iDOCK server}
      IDOCK_TOKEN: ${IDOCK_TOKEN:?set IDOCK_TOKEN to a token from the Deploy Agent page}
      IDOCK_AGENT_NAME: ${IDOCK_AGENT_NAME:-}
      IDOCK_AGENT_ID_FILE: /state/agent_id
    volumes:
      # Read-write so the dashboard can Start/Stop/Update; use :ro for monitoring only.
      - /var/run/docker.sock:/var/run/docker.sock
      - idock_agent_state:/state

volumes:
  idock_agent_state:
