-
Bug
-
Resolution: Done
-
Major
-
4.12.0
-
None
-
None
-
uShift Sprint 228, uShift Sprint 229, uShift Sprint 230
-
3
-
Rejected
-
False
-
Description of problem:
Certain Route defaults behave differently on MicroShift (using the CR handler) vs. OCP. The behavior should be the same as on OCP. Specifically: - spec.to.kind should default to "Service" if it's specified by the client as "" - spec.wildcardPolicy should default to "None" if it's specified by the client as "" - spec.tls.termination should default to "edge" if it's specified by the client as "" AND spec.tls.destinationCACertificate is specified by the client as "" - spec.tls.termination should default to "edge" if it's specified by the client as "Edge" - spec.tls.termination should default to "reencrypt" if it's specified by the client as "Reencrypt" - spec.tls.termination should default to "passthrough" if it's specified by the client as "Passthrough"
Version-Release number of selected component (if applicable):
4.12
How reproducible:
Always
Steps to Reproduce:
$ cat <<EOF | oc apply -f- apiVersion: route.openshift.io/v1 kind: Route metadata: name: hello-microshift spec: to: kind: "" name: hello-microshift EOF $ oc get route hello-microshift -o yaml
Actual results:
The Route "hello-microshift" is invalid: spec.to.kind: Invalid value: "": must reference a Service
Expected results:
apiVersion: route.openshift.io/v1 kind: Route metadata: name: hello-microshift namespace: default spec: to: kind: Service
Additional info:
The CR handler only applies defaults to fields that are omitted from the request body, or, if the field is not nullable per the schema, are serialized as null. This is why the above Route is accepted when spec.to.kind is absent, but rejected when present, even when empty.
- causes
-
OCPBUGS-4198 route-controller-manager not creating routes
- Closed
-
OCPBUGS-4199 route-controller-manager not creating routes in 4.12
- Closed
- is blocked by
-
OCPBUGS-4323 Route/v1 defaulting for target kind and termination must be sharable between openshift-apiserver and kube-apiserver
- Closed
-
OCPBUGS-4658 Use shared library in admission to default Routes served via CRD
- Closed
- is duplicated by
-
OCPBUGS-4575 [MicroShift] failed to create route by "oc expose service" command
- Closed
- is related to
-
API-1433 Complete Route API compatibility
- Closed
-
OCPBUGS-4657 Route defaulting package from library-go must be available for import by kube-apiserver admission plugins
- Closed
-
OCPBUGS-4808 Use shared library in admission to default Routes served via CRD
- Closed
- links to