charts
charts copied to clipboard
support using git-sync with PVC (allowing there to only be one git-sync container)
Currently, we don't let users enable dags.gitSync
and dags.persistence
at the same time.
If we do this (obviously requiring dags.persistence.accessMode = ReadWriteMany
), we can massively reduce the number of git-sync containers required.
This is because we won't have to put a git-sync container in every Pod, but rather have all pods mount the PVC, while having a central single git-sync deployment that keeps the PVC up to date.
in airflow1 version, gitSync with dags pvc works. we hope it keeps the same in airflow2. which would not leading the task container waiting for git clone done (this masters a lot if the git repo is too big or poor network connection)
@justbeay two comments:
- version
8.X.X
of the chart can be used with both airflow 1 and airflow 2 (see the Airflow Version Support table) - while the
7.X.X
version of the chart may have let you enable a PVC with git-sync enabled, it would have resulted in all the git-sync containers fighting over the sync
I think this feature is really important for KubernetesExecutor, as right now if cloning the git repo takes a long time, then EVERY task will take at least that long, this is because the git-clone
init-container must run before the task can, as it needs the DAG definitions.
I have created a PR trying to address these, I'd appreciate feedback on it.