docker-stacks/magneticod/docker-compose.yml

25 lines
838 B
YAML

version: '3.7'
services:
magneticod:
image: boramalper/magneticod:latest
container_name: magneticod
# Using host mode to be able to simply apply firewall rules to disable connection tracking
# https://github.com/boramalper/magnetico/blob/master/cmd/magneticod/README.md#setup
#network_mode: "host"
extra_hosts:
- 'host.docker.internal:host-gateway'
ports:
- "${MAGNETICO_PORT}:${MAGNETICO_PORT}/udp"
env_file: .env
#volumes:
# - "${HOST_DB_PATH}:/data"
user: "${HOST_USER}"
restart: unless-stopped
command: "-v --indexer-addr=0.0.0.0:${MAGNETICO_PORT} --indexer-max-neighbors=${MAGNETICO_NEIGHBORS} --database=${MAGNETICO_DATABASE_URL}"
logging:
driver: "json-file"
options:
max-size: "${LOG_MAX_SIZE:-5m}"
max-file: "${LOG_MAX_FILE:-5}"