-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
58 lines (50 loc) · 1.56 KB
/
docker-compose.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
name: airflow
x-airflow-variables: &airflow-variables
AIRFLOW__CORE__EXECUTOR: "SequentialExecutor" # Use LocalExecutor when running with postgres
AIRFLOW__CORE__LOAD_EXAMPLES: "False"
AIRFLOW__CORE__DAG_IGNORE_FILE_SYNTAX: "glob"
AIRFLOW__CORE__DAGS_FOLDER: "/opt/airflow/dags"
AIRFLOW__LOGGING__BASE_LOG_FOLDER: "/opt/airflow/logs"
AIRFLOW__LOGGING__LOGGING_LEVEL: WARNING
AIRFLOW_CONN_SLACK_API_DEFAULT: not-a-slack-conn
AIRFLOW__CORE__DAGS_ARE_PAUSED_AT_CREATION: "True"
x-common-variables: &common-variables
SECRET_KEY: ${SECRET_KEY}
ECS_SUBNET: $ECS_SUBNET
ECS_SECURITY_GROUP: $ECS_SECURITY_GROUP
AWS_DEFAULT_REGION: $AWS_DEFAULT_REGION
ENVIRONMENT: $ENVIRONMENT
services:
scheduler:
image: apache/airflow:2.10.5
container_name: airflow-scheduler
command: scheduler
restart: always
ports:
- "8793:8793"
environment:
<<: [*airflow-variables, *common-variables]
user: "${AIRFLOW_UID:-50000}:0"
volumes:
- data:/opt/airflow
webserver:
image: apache/airflow:2.10.5
container_name: airflow-webserver
command: webserver -w 4
ports:
- 4040:8080
restart: always
post_start:
- command: |
/usr/bin/dumb-init -- /entrypoint db migrate
environment:
<<: [*airflow-variables, *common-variables]
# AIRFLOW__WEBSERVER__SECRET_KEY: ${SECRET_KEY}
# FORWARDED_ALLOW_IPS: "*"
AIRFLOW__WEBSERVER__WORKER_CLASS: "gevent"
_AIRFLOW_PATCH_GEVENT: "1"
user: "${AIRFLOW_UID:-50000}:0"
volumes:
- data:/opt/airflow
volumes:
data: