-
Notifications
You must be signed in to change notification settings - Fork 14.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Bug Fix Pod-Template Affinity Ignored due to empty Affinity K8S Object (
#15787) **Issue**: KubernetesPodOperator pod-template files with pod affinities are ignored, even if no affinities are passed to the KubernetesPodOperator object. **Cause** During the pod-initialization an empty k8s.Affinity object is created if no affinities are supplied. This will later prevent the pod-template affinities to be used, because during the pod_reconciliation the empty k8s.Affinity object takes precedence. All other attributes such as `self.k8s_resources = convert_resources(resources) if resources else {}` `self.image_pull_secrets = convert_image_pull_secrets(image_pull_secrets) if image_pull_secrets else []` handle it properly.
- Loading branch information
Showing
2 changed files
with
49 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters