diff --git a/pkg/crd/crdvalidations.go b/pkg/crd/crdvalidations.go index 2e166e5f..54bd6cf2 100644 --- a/pkg/crd/crdvalidations.go +++ b/pkg/crd/crdvalidations.go @@ -371,12 +371,14 @@ var ( Description: "Image for containing the language runtime.", }, "container": { - Type: "object", - Description: "(Optional) Container allows the modification of the deployed runtime container using the Kubernetes Container spec. Fission overrides the following fields: Name, Image (set to the Runtime.Image), TerminationMessagePath, ImagePullPolicy\n You can set either PodSpec or Container, but not both.", + Type: "object", + Description: "(Optional) Container allows the modification of the deployed runtime container using the Kubernetes Container spec. Fission overrides the following fields: Name, Image (set to the Runtime.Image), TerminationMessagePath, ImagePullPolicy\n You can set either PodSpec or Container, but not both.", + XPreserveUnknownFields: boolPtr(true), }, "podspec": { - Type: "object", - Description: "(Optional) Podspec allows modification of deployed runtime pod with Kubernetes PodSpec.\n You can set either PodSpec or Container, but not both.\n More info for podspec:\n https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.19/#podspec-v1-core", + Type: "object", + Description: "(Optional) Podspec allows modification of deployed runtime pod with Kubernetes PodSpec.\n You can set either PodSpec or Container, but not both.\n More info for podspec:\n https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.19/#podspec-v1-core", + XPreserveUnknownFields: boolPtr(true), }, } runtimeSchema = apiextensionsv1beta1.JSONSchemaProps{ @@ -396,12 +398,14 @@ var ( Description: "(Optional) Default build command to run for this build environment.", }, "container": { - Type: "object", - Description: "(Optional) Container allows the modification of the deployed runtime container using the Kubernetes Container spec. Fission overrides the following fields: Name, Image (set to the Runtime.Image), TerminationMessagePath, ImagePullPolicy\n You can set either PodSpec or Container, but not both.", + Type: "object", + Description: "(Optional) Container allows the modification of the deployed runtime container using the Kubernetes Container spec. Fission overrides the following fields: Name, Image (set to the Runtime.Image), TerminationMessagePath, ImagePullPolicy\n You can set either PodSpec or Container, but not both.", + XPreserveUnknownFields: boolPtr(true), }, "podspec": { - Type: "object", - Description: "(Optional) Podspec allows modification of deployed runtime pod with Kubernetes PodSpec.\n You can set either PodSpec or Container, but not both.", + Type: "object", + Description: "(Optional) Podspec allows modification of deployed runtime pod with Kubernetes PodSpec.\n You can set either PodSpec or Container, but not both.", + XPreserveUnknownFields: boolPtr(true), }, } builderSchema = apiextensionsv1beta1.JSONSchemaProps{ diff --git a/test/test_utils.sh b/test/test_utils.sh index cb1300af..f3ad1aee 100755 --- a/test/test_utils.sh +++ b/test/test_utils.sh @@ -340,6 +340,8 @@ helm_uninstall_fission() {(set +e echo "Uninstalling fission" helm delete $id -n $ns || true kubectl delete ns f-$id || true + echo "Deleting CRDs" + kubectl get crd | grep "fission.io" | awk '{print $1}' | xargs -n1 kubectl delete crd )} export -f helm_uninstall_fission