Compare commits

...

2 Commits

Author SHA1 Message Date
Debby
ceccf69518 docker-compose-1V 2026-03-07 16:56:58 +07:00
Debby
3086e5ce50 first compose 2026-03-07 16:43:55 +07:00

View File

@@ -15,17 +15,15 @@ services:
depends_on: depends_on:
- postgres - postgres
environment: environment:
- PYTHONPATH=/opt/airflow - PYTHONPATH=/opt/airflow # Kunci agar folder scripts terbaca
- AIRFLOW__DATABASE__SQL_ALCHEMY_CONN=postgresql+psycopg2://airflow:airflow@postgres/airflow - AIRFLOW__DATABASE__SQL_ALCHEMY_CONN=postgresql+psycopg2://airflow:airflow@postgres/airflow
- AIRFLOW__CORE__EXECUTOR=LocalExecutor - AIRFLOW__CORE__EXECUTOR=LocalExecutor
- AIRFLOW__CORE__LOAD_EXAMPLES=False - AIRFLOW__CORE__LOAD_EXAMPLES=False
- GOOGLE_APPLICATION_CREDENTIALS=/opt/airflow/secrets/food-security-asean-project-826a4d7b302a.json
volumes: volumes:
- 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
- ./scripts:/opt/airflow/scripts - airflow_scripts:/opt/airflow/scripts
- ./secrets:/opt/airflow/secrets:ro
ports: ports:
- "8081:8080" - "8081:8080"
command: bash -c "airflow db init && airflow webserver" command: bash -c "airflow db init && airflow webserver"
@@ -39,17 +37,16 @@ services:
- PYTHONPATH=/opt/airflow - PYTHONPATH=/opt/airflow
- AIRFLOW__DATABASE__SQL_ALCHEMY_CONN=postgresql+psycopg2://airflow:airflow@postgres/airflow - AIRFLOW__DATABASE__SQL_ALCHEMY_CONN=postgresql+psycopg2://airflow:airflow@postgres/airflow
- AIRFLOW__CORE__EXECUTOR=LocalExecutor - AIRFLOW__CORE__EXECUTOR=LocalExecutor
- GOOGLE_APPLICATION_CREDENTIALS=/opt/airflow/secrets/food-security-asean-project-826a4d7b302a.json
volumes: volumes:
- 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
- ./scripts:/opt/airflow/scripts - airflow_scripts:/opt/airflow/scripts
- ./secrets:/opt/airflow/secrets:ro
command: scheduler command: scheduler
volumes: volumes:
postgres_data: postgres_data:
airflow_dags: airflow_dags:
airflow_logs: airflow_logs:
airflow_plugins: airflow_plugins:
airflow_scripts: