Route migration
Automatic route creation, also known as Istio OpenShift Routing (IOR), is a deprecated feature that is disabled by default for any ServiceMeshControlPlane resource that was created using Red Hat OpenShift Service Mesh 2.5 and later. Migrating from IOR to explicitly-managed routes provides a more flexible way to manage and configure ingress gateways. When route resources are explicitly created they can be managed alongside the other gateway and application resources as part of a GitOps management model.
Migrating from Istio OpenShift Routing to explicitly-managed routes
This procedure explains how to disable Istio OpenShift Routing (IOR) in Red Hat OpenShift Service Mesh, and how to continue to use and manage Routes that were originally created using IOR. This procedure also provides an example of how to explicitly create a new Route targeting an existing gateway Service object.
-
Before migrating to explicitly-managed routes, export the existing route configurations managed by Istio OpenShift Routing (IOR) to files. Save the files so that in the future you can recreate the route configurations without requiring IOR.
-
Modify the
ServiceMeshControlPlaneresource to disable IOR:apiVersion: maistra.io/v2 kind: ServiceMeshControlPlane spec: gateways: openshiftRoute: enabled: falseYou can continue to use the old routes that were previously created using IOR or you can create routes that explicitly target the ingress gateway
Serviceobject. The following example specifies how to create routes that explicitly target the ingress gatewayServiceobject:kind: Route apiVersion: route.openshift.io/v1 metadata: name: example-gateway namespace: istio-system spec: host: www.example.com to: kind: Service name: istio-ingressgateway weight: 100 port: targetPort: http2 wildcardPolicy: None- Specify new routes in the same namespace as the ingress gateway
Serviceobject. - Use the name of ingress gateway
Serviceobject that is the target.
- Specify new routes in the same namespace as the ingress gateway