267 lines
8.0 KiB
YAML
267 lines
8.0 KiB
YAML
---
|
|
# ═══════════════════════════════════════════════════════════════════════════════
|
|
# Stack ADS-B Linux-25 — 1 à 3 récepteurs, pilotés par profiles Compose
|
|
#
|
|
# Les services d'un récepteur sont conditionnés au profile rx<n>. La liste des
|
|
# profiles actifs et les numéros de série sont générés depuis le matériel
|
|
# réellement présent :
|
|
#
|
|
# /data/adsb/scripts/gen_env.sh
|
|
# docker compose --env-file .env.receivers up -d --remove-orphans
|
|
#
|
|
# Secrets : PG_PASSWORD est lu depuis .env (non versionné), plus en dur ici.
|
|
# ═══════════════════════════════════════════════════════════════════════════════
|
|
|
|
x-readsb-common: &readsb-common
|
|
image: ghcr.io/sdr-enthusiasts/docker-readsb-protobuf:latest
|
|
restart: unless-stopped
|
|
privileged: true
|
|
devices:
|
|
- /dev/bus/usb:/dev/bus/usb
|
|
networks:
|
|
- adsb-net
|
|
tmpfs:
|
|
- /var/log:size=32M
|
|
|
|
x-readsb-env: &readsb-env
|
|
TZ: Europe/Paris
|
|
READSB_DCFILTER: "true"
|
|
READSB_DEVICE_TYPE: rtlsdr
|
|
READSB_FIX: "true"
|
|
READSB_LAT: "48.8236"
|
|
READSB_LON: "2.2770"
|
|
# READSB_MODEAC: "true"
|
|
READSB_RX_LOCATION_ACCURACY: "2"
|
|
READSB_STATS_RANGE: "true"
|
|
READSB_NET_ENABLE: "true"
|
|
|
|
x-tar1090-common: &tar1090-common
|
|
image: ghcr.io/sdr-enthusiasts/docker-tar1090:latest
|
|
restart: unless-stopped
|
|
networks:
|
|
- adsb-net
|
|
tmpfs:
|
|
- /run/tar1090:size=64M
|
|
- /var/log:size=32M
|
|
|
|
x-tar1090-env: &tar1090-env
|
|
TZ: Europe/Paris
|
|
LAT: "48.8236"
|
|
LONG: "2.2770"
|
|
TAR1090_DEFAULTCENTERLAT: "48.8236"
|
|
TAR1090_DEFAULTCENTERLON: "2.2770"
|
|
TAR1090_DEFAULTZOOM: "10"
|
|
TAR1090_PLANECOUNTINTITLE: "true"
|
|
TAR1090_ENABLE_AC_DB: "true"
|
|
|
|
x-pg-env: &pg-env
|
|
PG_HOST: 127.0.0.1
|
|
PG_PORT: "5432"
|
|
PG_USER: pgz_admin
|
|
PG_PASSWORD: ${PG_PASSWORD:?PG_PASSWORD manquant — le définir dans /data/adsb/.env}
|
|
PG_DB: wpz_postgres
|
|
PG_SCHEMA: adsb
|
|
|
|
services:
|
|
|
|
# ═══════════════════════════════════════════════════════════════
|
|
# Services permanents (indépendants du nombre de dongles)
|
|
# ═══════════════════════════════════════════════════════════════
|
|
|
|
webapp:
|
|
build: ./webapp
|
|
container_name: adsb-webapp
|
|
restart: unless-stopped
|
|
network_mode: host
|
|
environment:
|
|
<<: *pg-env
|
|
TZ: Europe/Paris
|
|
TAR1090_URL: http://127.0.0.1:8090
|
|
APP_TITLE: ADS-B Linux-25
|
|
STATION_LAT: "48.8236"
|
|
STATION_LON: "2.2770"
|
|
|
|
# ═══════════════════════════════════════════════════════════════
|
|
# Slot rx1 — ports 8090 / 30002 / 30003 / 30005
|
|
# ═══════════════════════════════════════════════════════════════
|
|
|
|
readsb:
|
|
<<: *readsb-common
|
|
container_name: adsb-readsb
|
|
profiles: ["rx1"]
|
|
environment:
|
|
<<: *readsb-env
|
|
READSB_RTLSDR_DEVICE: ${RX1_SERIAL}
|
|
READSB_GAIN: ${RX1_GAIN:-autogain}
|
|
READSB_NET_SBS_OUTPUT_PORT: "30003"
|
|
READSB_NET_BEAST_OUTPUT_PORT: "30005"
|
|
READSB_NET_RAW_OUTPUT_PORT: "30002"
|
|
ports:
|
|
- "127.0.0.1:30003:30003"
|
|
- "30005:30005"
|
|
- "127.0.0.1:30002:30002"
|
|
volumes:
|
|
- readsb-run:/run/readsb
|
|
|
|
tar1090:
|
|
<<: *tar1090-common
|
|
container_name: adsb-tar1090
|
|
profiles: ["rx1"]
|
|
depends_on:
|
|
- readsb
|
|
ports:
|
|
- "8090:8090"
|
|
environment:
|
|
<<: *tar1090-env
|
|
BEASTHOST: readsb
|
|
BEASTPORT: "30005"
|
|
TAR1090_PAGETITLE: ADS-B Linux-25
|
|
TAR1090_NGINX_PORT: "8090"
|
|
volumes:
|
|
- readsb-run:/run/readsb
|
|
|
|
adsb2pg:
|
|
build: ./adsb2pg
|
|
container_name: adsb-adsb2pg
|
|
profiles: ["rx1"]
|
|
restart: unless-stopped
|
|
network_mode: host
|
|
environment:
|
|
<<: *pg-env
|
|
TZ: Europe/Paris
|
|
DUMP1090_URL: http://127.0.0.1:8090/data/aircraft.json
|
|
POLL_INTERVAL: "5"
|
|
RECEIVER_SERIAL: ${RX1_SERIAL}
|
|
TAR1090_DB_PATH: /tar1090-db
|
|
|
|
# ═══════════════════════════════════════════════════════════════
|
|
# Slot rx2 — ports 8091 / 30012 / 30013 / 30015
|
|
# ═══════════════════════════════════════════════════════════════
|
|
|
|
readsb2:
|
|
<<: *readsb-common
|
|
container_name: adsb-readsb2
|
|
profiles: ["rx2"]
|
|
environment:
|
|
<<: *readsb-env
|
|
READSB_RTLSDR_DEVICE: ${RX2_SERIAL}
|
|
READSB_GAIN: ${RX2_GAIN:-autogain}
|
|
READSB_NET_SBS_OUTPUT_PORT: "30013"
|
|
READSB_NET_BEAST_OUTPUT_PORT: "30015"
|
|
READSB_NET_RAW_OUTPUT_PORT: "30012"
|
|
ports:
|
|
- "127.0.0.1:30013:30013"
|
|
- "30015:30015"
|
|
- "127.0.0.1:30012:30012"
|
|
volumes:
|
|
- readsb2-run:/run/readsb
|
|
|
|
tar10902:
|
|
<<: *tar1090-common
|
|
container_name: adsb-tar10902
|
|
profiles: ["rx2"]
|
|
depends_on:
|
|
- readsb2
|
|
ports:
|
|
- "8091:8091"
|
|
environment:
|
|
<<: *tar1090-env
|
|
BEASTHOST: readsb2
|
|
BEASTPORT: "30015"
|
|
TAR1090_PAGETITLE: ADS-B Linux-25 (récepteur 2)
|
|
TAR1090_NGINX_PORT: "8091"
|
|
volumes:
|
|
- readsb2-run:/run/readsb
|
|
|
|
adsb2pg2:
|
|
build: ./adsb2pg
|
|
container_name: adsb-adsb2pg2
|
|
profiles: ["rx2"]
|
|
restart: unless-stopped
|
|
network_mode: host
|
|
environment:
|
|
<<: *pg-env
|
|
TZ: Europe/Paris
|
|
DUMP1090_URL: http://127.0.0.1:8091/data/aircraft.json
|
|
POLL_INTERVAL: "5"
|
|
RECEIVER_SERIAL: ${RX2_SERIAL}
|
|
TAR1090_DB_PATH: /tar1090-db
|
|
|
|
# ═══════════════════════════════════════════════════════════════
|
|
# Slot rx3 — ports 8092 / 30022 / 30023 / 30025
|
|
# ═══════════════════════════════════════════════════════════════
|
|
|
|
readsb3:
|
|
<<: *readsb-common
|
|
container_name: adsb-readsb3
|
|
profiles: ["rx3"]
|
|
environment:
|
|
<<: *readsb-env
|
|
READSB_RTLSDR_DEVICE: ${RX3_SERIAL}
|
|
READSB_GAIN: ${RX3_GAIN:-autogain}
|
|
READSB_NET_SBS_OUTPUT_PORT: "30023"
|
|
READSB_NET_BEAST_OUTPUT_PORT: "30025"
|
|
READSB_NET_RAW_OUTPUT_PORT: "30022"
|
|
ports:
|
|
- "127.0.0.1:30023:30023"
|
|
- "30025:30025"
|
|
- "127.0.0.1:30022:30022"
|
|
volumes:
|
|
- readsb3-run:/run/readsb
|
|
|
|
tar10903:
|
|
<<: *tar1090-common
|
|
container_name: adsb-tar10903
|
|
profiles: ["rx3"]
|
|
depends_on:
|
|
- readsb3
|
|
ports:
|
|
- "8092:8092"
|
|
environment:
|
|
<<: *tar1090-env
|
|
BEASTHOST: readsb3
|
|
BEASTPORT: "30025"
|
|
TAR1090_PAGETITLE: ADS-B Linux-25 (récepteur 3)
|
|
TAR1090_NGINX_PORT: "8092"
|
|
volumes:
|
|
- readsb3-run:/run/readsb
|
|
|
|
adsb2pg3:
|
|
build: ./adsb2pg
|
|
container_name: adsb-adsb2pg3
|
|
profiles: ["rx3"]
|
|
restart: unless-stopped
|
|
network_mode: host
|
|
environment:
|
|
<<: *pg-env
|
|
TZ: Europe/Paris
|
|
DUMP1090_URL: http://127.0.0.1:8092/data/aircraft.json
|
|
POLL_INTERVAL: "5"
|
|
RECEIVER_SERIAL: ${RX3_SERIAL}
|
|
TAR1090_DB_PATH: /tar1090-db
|
|
|
|
networks:
|
|
adsb-net:
|
|
name: adsb-net
|
|
driver: bridge
|
|
|
|
volumes:
|
|
readsb-run:
|
|
driver: local
|
|
driver_opts:
|
|
type: tmpfs
|
|
device: tmpfs
|
|
o: size=64m
|
|
readsb2-run:
|
|
driver: local
|
|
driver_opts:
|
|
type: tmpfs
|
|
device: tmpfs
|
|
o: size=64m
|
|
readsb3-run:
|
|
driver: local
|
|
driver_opts:
|
|
type: tmpfs
|
|
device: tmpfs
|
|
o: size=64m
|