Repository navigation
Added Labels to dagprocessor in helm chart - #53358
tanujdargan wants to merge 7 commits into
Conversation
|
I think the dag-processor-serviceaccount (https://github.com/apache/airflow/blob/main/chart/templates/dag-processor/dag-processor-serviceaccount.yaml#L40) is also missing the addition of .Values.dagProcessor.labels alongside mustMerge. A similar example to lookup (https://github.com/apache/airflow/blob/main/chart/templates/api-server/api-server-serviceaccount.yaml#L36) |
prakass1
left a comment
There was a problem hiding this comment.
All previous things now seem to expect the values.schema.json. Once fixed, it should pass the unit test and be ready to merge I think.
Is added. |
|
This pull request has been automatically marked as stale because it has not had recent activity. It will be closed in 5 days if no further activity occurs. Thank you for your contributions. |
| {{- if or (.Values.labels) (.Values.dagProcessor.labels) }} | ||
| {{- $global := default (dict) .Values.labels -}} | ||
| {{- $component := default (dict) .Values.dagProcessor.labels -}} | ||
| {{- mustMerge $global $component | toYaml | nindent 4 }} |
There was a problem hiding this comment.
Was trying out this PR because we needed to label the dagProcessor. But when using KubernetesExecutor, worker pods were being spawned with the labels meant for the dagProcessor. The above code seems to be causing it.
From helm docs:
mustMerge does not create a deep copy of the dictionaries, so this will inject the dagProcessor labels into the global values. I think line 50 should be:
{{- $global := deepCopy (default (dict) .Values.labels) -}}
| {{- if or (.Values.labels) (.Values.dagProcessor.labels) }} | ||
| {{- $global := default (dict) .Values.labels -}} | ||
| {{- $component := default (dict) .Values.dagProcessor.labels -}} | ||
| {{- mustMerge $component $global | toYaml | nindent 4 }} |
There was a problem hiding this comment.
same as comment above to prevent merging global values
|
FYI: There is a small discussion regarding a similar change in #59290 |
|
This pull request has been automatically marked as stale because it has not had recent activity. It will be closed in 5 days if no further activity occurs. Thank you for your contributions. |
Closes: #53190
New Features
Tests