New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add docker-compose-airflow #5757
Add docker-compose-airflow #5757
Conversation
This is almost exactly the Airflow docker-compose, except we add a lakeFS connector as part of setup. To use: ```sh docker compose -f docker-compose.yml -f docker-compose-airflow.yml up -d ``` == Why a separate docker-compose file? == 1. Airflow requires _multiple_ services. This makes patching the one required docker-compose file easier. 1. Anyway many (most?) users won't want all these services. Using profiles to load Airflow inside the same docker-compose file would only cause _more_ differences, and add no value to users. == How was this tested? == I brought up all services in _both_ docker-compose files using `docker compose`. Then I copied `treeverse/airflow-provider-lakeFS/lakefs_provider/example_dags/lakefs-dag.py` into `./dags/`. I created a repo example-repo on http://localhost:8080/ (the lakeFS instance). I had to restart airflow-scheduler, but after that it found my DAG and I was able to run the lakeFS example dag http://localhost:8000/ (the Airflow instance).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To review: there is exactly one line changed in docker-compose-airflow.yml, it is marked on this object.
AIRFLOW__SCHEDULER__ENABLE_HEALTH_CHECK: 'true' | ||
# WARNING: Use _PIP_ADDITIONAL_REQUIREMENTS option ONLY for a quick checks | ||
# for other purpose (development, test and especially production usage) build/extend Airflow image. | ||
_PIP_ADDITIONAL_REQUIREMENTS: ${_PIP_ADDITIONAL_REQUIREMENTS:-} airflow-provider-lakefs>=0.45.0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewer please note: this is the only change to the Airflow docker-compose file!
|
@arielshaqed thanks for the note. Is there a readme or docs to go with this? |
You're right, there will be. Documentation for the Everything Bagel docker-compose is somewhat lacking already. No excuse for keeping it that way, though. PTAL. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks @arielshaqed.
EB docs and general state is closely on my radar for attention soon :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very cool
Thank you!
Thanks! Pulling... |
This is almost exactly the Airflow docker-compose, except we add a lakeFS
connector as part of setup.
To use:
Why a separate docker-compose file?
required docker-compose file easier.
to load Airflow inside the same docker-compose file would only cause
more differences, and add no value to users.
How was this tested?
I brought up all services in both docker-compose files using
docker compose
. Then I copiedtreeverse/airflow-provider-lakeFS/lakefs_provider/example_dags/lakefs-dag.py
into
./dags/
. I created a repo example-repo onhttp://localhost:8080/ (the lakeFS instance). I had to restart
airflow-scheduler, but after that it found my DAG and I was able to run the
lakeFS example dag http://localhost:8000/ (the Airflow instance).
Fixes #5677.