Skip to content

Instantly share code, notes, and snippets.

@pablohdzvizcarra
Created September 19, 2024 13:24
Show Gist options
  • Save pablohdzvizcarra/a36c0a439c8e4631b79d9d15f7b94a3b to your computer and use it in GitHub Desktop.
Save pablohdzvizcarra/a36c0a439c8e4631b79d9d15f7b94a3b to your computer and use it in GitHub Desktop.
Docker compose file to override the default configuration for Apache airflow running with the astro CLI too.l
version: "3.1"
services:
webserver:
networks:
- ndsnet
scheduler:
networks:
- ndsnet
triggerer:
networks:
- ndsnet
minio:
image: minio/minio:RELEASE.2024-06-13T22-53-53Z
container_name: minio
hostname: minio
restart: always
volumes:
- ./include/data/minio:/data
ports:
- 9000:9000
- 9001:9001
environment:
MINIO_ROOT_USER: minio
MINIO_ROOT_PASSWORD: minio123
command: server /data --console-address ":9001"
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:9000/minio/health/live"]
interval: 30s
timeout: 20s
retries: 3
networks:
- ndsnet
spark-master:
image: airflow/spark-master
build: ./spark/master
container_name: spark-master
ports:
- "8082:8080"
- "7077:7077"
environment:
- INIT_DAEMON_STEP=setup_spark
- SPARK_MODE=master
networks:
- ndsnet
spark-worker:
image: airflow/spark-worker
build: ./spark/worker
container_name: spark-worker
depends_on:
- spark-master
ports:
- "8081:8081"
environment:
- SPARK_MODE=worker
- SPARK_MASTER=spark://spark-master:7077
- SPARK_WORKER_CORES=2
- SPARK_WORKER_MEMORY=2g
networks:
- ndsnet
metabase:
image: metabase/metabase:v0.50.4
restart: always
ports:
- 3000:3000
volumes:
- ./include/data/metabase:/metabase-data
networks:
- ndsnet
docker-proxy:
image: alpine/socat
command: "TCP4-LISTEN:2375,fork,reuseaddr UNIX-CONNECT:/var/run/docker.sock"
ports:
- "2376:2375"
volumes:
- /var/run/docker.sock:/var/run/docker.sock
networks:
- ndsnet
networks:
ndsnet:
driver: bridge
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment