Skip to content
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

Closed
wants to merge 1 commit into from

Conversation

patchkez
Copy link
Contributor

No description provided.

Copy link
Contributor

@Victoremepunto Victoremepunto left a 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

Comment on lines +177 to +194
- 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
Copy link
Contributor

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}
Copy link
Contributor

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"

Comment on lines +166 to +169
- name: FRONTEND_ROUTE_CNAME
displayName: Frontend Route
description: The CNAME URL of the frontend of the Ibutsu server
value: ibutsu.prod.com
Copy link
Contributor

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 ?

@mshriver mshriver closed this Nov 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants