You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This repo is highly inspired by another similar work done here.
The only reason I re-attempted it, so that I can get the first hand experience and also resolve some difficulties I
faced while using the above solution.
Build an Airflow pex by running:
./pants binary src/python/ariflow:airflow
This produces airflow.pex, a single file that is analogous to a statically-lined binary. It's a self-contained,
runnable Airflow you can scp to another machine and run. However, ideally you would zip this whole folder and scp
to remote machine.
You can then run Airflow commands, using airflow_cli wrapper, which internally calls the airflow.pex file. You can
also use this wrapper file to modify the Airflow config variables.
If you've noticed the dags and plugins folder are part of airflow_home folder, but ideally they should be part of
the airflow.pex itself. We can easily bundle dags and plugins as well in the airflow.pex like we've bundled libs
folder, but unfortunately Airflow can't read them from airflow.pex/dags or airflow.pex/plugins directly, so you can
unzip the final PEX at the server and move them inside airflow_home folder.