brandonwillard commented on a change in pull request #8150: [AIRFLOW-3126] Add 
option to specify additional K8s volumes
URL: https://github.com/apache/airflow/pull/8150#discussion_r405158858
 
 

 ##########
 File path: airflow/executors/kubernetes_executor.py
 ##########
 @@ -241,6 +245,69 @@ def _get_security_context_val(self, scontext: str) -> 
Union[str, int]:
         else:
             return int(val)
 
+    def _parse_extra_volume_mounts(self) -> Dict[str, Dict[str, Any]]:
+        res: Dict[str, Dict[str, Any]] = {}
+
+        extra_volume_mounts = conf.get(self.kubernetes_section, 
'extra_volume_mounts')
+
+        if extra_volume_mounts:  # pylint: disable=too-many-nested-blocks
+
+            try:
+                res = json.loads(extra_volume_mounts)
+            except JSONDecodeError as e:
+                raise AirflowConfigException(
+                    'Error parsing config option'
+                    ' `extra_volume_mounts`: {}.'.format(e))
+
+            for pvc_name, pvc_settings in res.items():
+                if 'mount_path' not in pvc_settings:
 
 Review comment:
   Yeah, no problem.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to