Update docker-compose.yaml
This commit is contained in:
@@ -24,7 +24,8 @@ services:
|
|||||||
- airflow_plugins:/opt/airflow/plugins
|
- airflow_plugins:/opt/airflow/plugins
|
||||||
ports:
|
ports:
|
||||||
- "8081:8080"
|
- "8081:8080"
|
||||||
command: webserver
|
# Perintah di bawah akan inisialisasi DB dulu baru menyalakan webserver
|
||||||
|
command: bash -c "airflow db init && airflow webserver"
|
||||||
|
|
||||||
airflow-scheduler:
|
airflow-scheduler:
|
||||||
build: .
|
build: .
|
||||||
@@ -38,10 +39,11 @@ services:
|
|||||||
- airflow_dags:/opt/airflow/dags
|
- airflow_dags:/opt/airflow/dags
|
||||||
- airflow_logs:/opt/airflow/logs
|
- airflow_logs:/opt/airflow/logs
|
||||||
- airflow_plugins:/opt/airflow/plugins
|
- airflow_plugins:/opt/airflow/plugins
|
||||||
|
# Scheduler menunggu webserver selesai init DB
|
||||||
command: scheduler
|
command: scheduler
|
||||||
|
|
||||||
volumes:
|
volumes:
|
||||||
postgres_data:
|
postgres_data:
|
||||||
airflow_dags: # Menggunakan Named Volume
|
airflow_dags:
|
||||||
airflow_logs: # Menggunakan Named Volume
|
airflow_logs:
|
||||||
airflow_plugins: # Menggunakan Named Volume
|
airflow_plugins:
|
||||||
Reference in New Issue
Block a user