Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

KubernetesExecutor should accept images from executor_config #13074

Merged
merged 2 commits into from
Jan 12, 2021
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion airflow/kubernetes/pod_generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -535,9 +535,15 @@ def construct_pod(
- executor_config
- dynamic arguments
"""
try:
image = pod_override_object.spec.containers[0].image # type: ignore
if not image:
image = kube_image
except Exception: # pylint: disable=W0703
image = kube_image
dynamic_pod = PodGenerator(
namespace=namespace,
image=kube_image,
image=image,
labels={
'airflow-worker': worker_uuid,
'dag_id': make_safe_label_value(dag_id),
Expand Down