liveBook · Manning

Persistent volume

As explained in Data Pipelines with Apache Airflow, Second Edition

A PersistentVolume is Kubernetes storage provisioned for use by workloads independently of a pod's lifecycle.

A PersistentVolume is Kubernetes storage that lets Airflow mount shared DAG files independently of individual pod images. It hides the underlying storage technology, but teams must still arrange a way to push or pull DAG code onto the volume. section 17.2.7

Mounting DAGs from a local volume

Declare a ReadWriteMany PersistentVolume backed by the host's /data directory, bind it to a 250Mi PersistentVolumeClaim, and apply the manifest with kubectl. Configure the Airflow Helm chart with dags.persistence.enabled: true and existingClaim: local-path-dag-volume-claim, then deploy with helm upgrade.

This approach suits multiple teams sharing an Airflow environment, but its CI/CD design depends on the chosen volume type. Git synchronization is an alternative when DAGs should come from a repository instead. section 17.2.7

How Data Pipelines with Apache Airflow, Second Edition covers it

How deep it goes
Defines the storage abstraction and demonstrates YAML, kubectl, and Helm configuration, but defers volume-specific CI/CD implementation.
Examples
Uses a hostPath-backed ReadWriteMany volume, a 250Mi claim, kubectl apply, and an Airflow Helm deployment.
What you can do after
Operate/configure Airflow DAG storage through Kubernetes manifests and Helm values using an existing PersistentVolumeClaim.
How it connects
Connects PersistentVolume with Kubernetes volumes, PersistentVolumeClaim, Airflow Helm configuration, DAG deployment, and CI/CD.

Also explained in

Compare how 7 books explain persistent volume →

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Data Pipelines with Apache Airflow, Second Edition. The section links point to the parts of the book it draws on.