Skip to content

Commit

Permalink
# CG Hack: keep the volume mapping for mounting other repositories
Browse files Browse the repository at this point in the history
  • Loading branch information
Lihan Li committed Dec 3, 2020
1 parent 5b61c21 commit 8dc47a3
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions airflow/kubernetes/worker_configuration.py
Original file line number Diff line number Diff line change
Expand Up @@ -305,8 +305,9 @@ def _get_volume_mounts(self):
if self.kube_config.logs_volume_subpath:
volume_mounts[self.logs_volume_name].sub_path = self.kube_config.logs_volume_subpath

if self.kube_config.dags_in_image:
del volume_mounts[self.dags_volume_name]
# CG Hack: keep the volume mapping for mounting other repositories
# if self.kube_config.dags_in_image:
# del volume_mounts[self.dags_volume_name]

# Mount the airflow.cfg file via a configmap the user has specified
if self.kube_config.airflow_configmap:
Expand Down Expand Up @@ -371,9 +372,9 @@ def _construct_volume(name, claim, host):
self.kube_config.logs_volume_host
)
}

if self.kube_config.dags_in_image:
del volumes[self.dags_volume_name]
# CG Hack: keep the volume mapping for mounting other repositories
# if self.kube_config.dags_in_image:
# del volumes[self.dags_volume_name]

# Get the SSH key from secrets as a volume
if self.kube_config.git_ssh_key_secret_name:
Expand Down

0 comments on commit 8dc47a3

Please sign in to comment.