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

Re-add mistakenly removed patch for invalid manifest fields creationTimestamp: "null" #142

Merged
merged 3 commits into from
Jun 30, 2023
Merged
Show file tree
Hide file tree
Changes from 2 commits
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
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Changed

- Replace deprecated kustomize config `patchesStrategicMerge`
- Fail crd-install on `kubectl get` error
- Re-add mistakenly removed patch for invalid manifest fields `creationTimestamp: "null"`

### Fixed

Expand Down
6 changes: 6 additions & 0 deletions config/helm/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,12 @@ patches:
patch: |-
- op: remove
path: /spec/template/spec/securityContext/seccompProfile
- target:
kind: CustomResourceDefinition
name: (ipaddressclaims\.ipam|extensionconfigs\.runtime|ipaddresses\.ipam).cluster.x-k8s.io
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

label selector would also work

patch: |-
- op: remove
path: /metadata/creationTimestamp

# Upstream defaults to `Always` but since we use images that are not changing (`vX.Y.Z` or commit SHA), we prefer `IfNotPresent`
- target:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ metadata:
annotations:
cert-manager.io/inject-ca-from: '{{ .Release.Namespace }}/capi-serving-cert'
controller-gen.kubebuilder.io/version: v0.11.3
creationTimestamp: "null"
labels:
app.giantswarm.io/branch: '{{ .Values.project.branch }}'
app.giantswarm.io/commit: '{{ .Values.project.commit }}'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ metadata:
annotations:
cert-manager.io/inject-ca-from: '{{ .Release.Namespace }}/capi-serving-cert'
controller-gen.kubebuilder.io/version: v0.11.3
creationTimestamp: "null"
labels:
app.giantswarm.io/branch: '{{ .Values.project.branch }}'
app.giantswarm.io/commit: '{{ .Values.project.commit }}'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ metadata:
annotations:
cert-manager.io/inject-ca-from: '{{ .Release.Namespace }}/capi-serving-cert'
controller-gen.kubebuilder.io/version: v0.11.3
creationTimestamp: "null"
labels:
app.giantswarm.io/branch: '{{ .Values.project.branch }}'
app.giantswarm.io/commit: '{{ .Values.project.commit }}'
Expand Down
4 changes: 2 additions & 2 deletions helm/cluster-api/templates/crd-install/crd-job.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,10 @@ spec:
- name: kubectl
image: "{{ .Values.images.domain }}/giantswarm/kubectl:1.24.9"
command:
- sh
- bash
- -c
- |
set -o errexit ; set -o xtrace ; set -o nounset
set -o errexit ; set -o xtrace ; set -o nounset ; set -o pipefail

for crd in $(kubectl get crds -o json | jq -r '.items[] | select(.metadata.name | test("cluster.x-k8s.io")) | select(.status.storedVersions | index("v1alpha2")) | .metadata.name'); do
index=$(kubectl get crds ${crd} -o json | jq -r '.status.storedVersions | index("v1alpha2")')
Expand Down
Loading