# The CameraRisk monitor with Docker Compose. Put this file, camerarisk-agent.mjs and
# camerarisk-agent.Dockerfile in one folder, then:
#
#   docker compose build
#   docker compose run --rm camerarisk-agent pair ABCD-EFGH
#   docker compose run --rm camerarisk-agent add
#   docker compose up -d
#
# The named volume holds the config (this monitor's pairing and your cameras, passwords included).
services:
  camerarisk-agent:
    build:
      context: .
      dockerfile: camerarisk-agent.Dockerfile
    image: camerarisk-agent
    restart: unless-stopped
    volumes:
      - camerarisk-agent:/config
    # Cameras with .local names: mDNS does not reach Docker's default network. Use their IP
    # addresses, or uncomment the next line.
    # network_mode: host
volumes:
  camerarisk-agent:
