Skip to content
This repository has been archived by the owner on Oct 22, 2021. It is now read-only.

fix: mutating deployment selector on apps-dns #1370

Merged
merged 6 commits into from
Sep 24, 2020

Conversation

f0rmiga
Copy link
Member

@f0rmiga f0rmiga commented Sep 23, 2020

This PR fixes upgrades from KubeCF 2.5 to next.

Error: UPGRADE FAILED: cannot patch "apps-dns" with kind Deployment: Deployment.apps "apps-dns" is invalid: spec.selector: Invalid value: v1.LabelSelector{MatchLabels:map[string]string{"app":"apps-dns", "app.kubernetes.io/instance":"susecf-scf", "app.kubernetes.io/managed-by":"Helm", "app.kubernetes.io/name":"susecf-scf-kubecf", "app.kubernetes.io/version":"0.2.0-1952.g99e5ce80", "helm.sh/chart":"kubecf-0.2.0-1952.g99e5ce80"}, MatchExpressions:[]v1.LabelSelectorRequirement(nil)}: field is immutable

viovanov
viovanov previously approved these changes Sep 23, 2020
@cfcontainerizationbot cfcontainerizationbot added the pr-test-queue PRs with this label get tested label Sep 23, 2020
@github-actions github-actions bot removed the pr-test-queue PRs with this label get tested label Sep 23, 2020
Renaming apps-dns deployment to cf-apps-dns to get rid of the bad labels
and selectors have the desired effect.

Signed-off-by: Thulio Ferraz Assis <thulio.assis@suse.com>
jandubois
jandubois previously approved these changes Sep 24, 2020
@cfcontainerizationbot cfcontainerizationbot added the pr-test-queue PRs with this label get tested label Sep 24, 2020
@github-actions github-actions bot removed the pr-test-queue PRs with this label get tested label Sep 24, 2020
@cfcontainerizationbot cfcontainerizationbot added the pr-test-queue PRs with this label get tested label Sep 24, 2020
@github-actions github-actions bot removed the pr-test-queue PRs with this label get tested label Sep 24, 2020
@mook-as
Copy link
Contributor

mook-as commented Sep 24, 2020

FWIW, we now have standard helper templates for selectors & labels that shouldn't have this issue. (This is mostly helpful for future changes.)

@viovanov viovanov merged commit 780b14c into master Sep 24, 2020
@viovanov viovanov deleted the f0rmiga/remove-mutating-selector branch September 24, 2020 21:26
@fargozhu fargozhu added the changelog Issue must be present in the release notes. label Sep 25, 2020
@fargozhu fargozhu added this to the 2.5.1 milestone Sep 25, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
changelog Issue must be present in the release notes.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants