-
Notifications
You must be signed in to change notification settings - Fork 23
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
Add route for CNAME records for frontend and backend services #482
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I understand what this PR is trying to do, but I don't understand why we need to add additional routes.
There's a potential breakage of the Service if the label is used with the default values too, I think this needs a small review
- apiVersion: route.openshift.io/v1 | ||
kind: Route | ||
metadata: | ||
annotations: | ||
description: A route to the backend | ||
labels: | ||
app: ${APP_NAME} | ||
shard: internal | ||
name: ibutsu-backend | ||
namespace: ${NAMESPACE} | ||
spec: | ||
host: ${BACKEND_ROUTE_CNAME} | ||
tls: | ||
insecureEdgeTerminationPolicy: Redirect | ||
termination: edge | ||
to: | ||
kind: Service | ||
name: ibutsu-backend |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why are we creating 2 routes ? shouldn't we just have the first one ? (the one that's used by the CNAME ?)
@@ -25,7 +25,7 @@ objects: | |||
template: | |||
metadata: | |||
labels: | |||
app: ibutsu-backend | |||
app: ${APP_NAME} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is going to break the Service if the APP_NAME is not set correctly, the APP_NAME's default value is ibutsu-server
- which is also used by all the other templates (with the same value), while the Service's label selector should use a unique value (otherwise more than one pod will match "app=ibutsu-server"
- name: FRONTEND_ROUTE_CNAME | ||
displayName: Frontend Route | ||
description: The CNAME URL of the frontend of the Ibutsu server | ||
value: ibutsu.prod.com |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we need separate route parameters ? can't we use just 1 route, set the value at creation time with the CNAME URL ?
No description provided.