The purpose of this document is to present how Openshift Routes are supported by kuryr-kubernetes.
OpenShift Origin [1] is an open source cloud application development and hosting platform that automates the provisioning, management and scaling of applications.
OpenShift Origin is a distribution of Kubernetes optimized for continuous application development and multi-tenancy deployment. OpenShift adds developer and operations-centric tools on top of Kubernetes to enable rapid application development, easy deployment and scaling, and long-term lifecycle maintenance.
An OpenShift Route [2] exposes a Service at a host name, like www.example.com, so that external clients can reach it by name. The Route is an Openshift resource that defines the rules you want to apply to incoming connections. The Openshift Routes concept introduced before Ingress [3] was supported by kubernetes, the Openshift Route matches the functionality of kubernetes Ingress.
The solution will rely on L7 router, Service/Endpoints handler and L7 router driver components described at kuryr-kubernetes Ingress integration design, where a new component - OCP-Route handler, will satisfy requests for Openshift Route resources.
The controller handlers should be extended to support OCP-Route resource.
The OCP-Route handler watches the apiserver’s for updates to Openshift Route resources. The following scheme describes OCP-Route controller SW architecture:
Similar to Kubernetes Ingress, each OCP-Route object being translated to a L7 policy in L7 router, and the rules on OCP-Route become L7 (URL) mapping rules in that L7 policy. The L7 policy is configured to forward the filtered traffic to LbaaS Pool. The LbaaS pool represents an Endpoints resource, and it’s the Service/Endpoints handler responsibility to attach all its members to this pool. Since the Endpoints resource is not aware of changes in OCP-Route objects pointing to it, the OCP-Route handler should trigger this notification, the notification will be implemented using annotation of the relevant Endpoint resource.
This section describes in details the following scenarios:
- Create OCP-Route, create Service/Endpoints.
- Create Service/Endpoints, create OCP-Route, delete OCP-Route.
Create OCP-Route, create Service/Endpoints:
OCP-Route is created under namespace ‘mynamespace’
apiVersion: v1
kind: Route
metadata:
name: test
spec:
host: www.example.com
to:
kind: Service
name: s1
Service/Endpoints is created under namespace ‘mynamespace’
Create Service/Endpoints, create OCP-Route, delete OCP-Route:
Except where otherwise noted, this document is licensed under Creative Commons Attribution 3.0 License. See all OpenStack Legal Documents.