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 subdomain support #779

Closed
wants to merge 1 commit into from

Conversation

mbaldessari
Copy link
Contributor

@mbaldessari mbaldessari commented Aug 30, 2022

This change adds route subdomain support (documented at [1]). One of the
reasons for adding this is that setting a subdomain requires no
knowledge at all of the global ingress domain of the cluster.
Since kubernetes has no concept of cluster name [2] and proposals to
change that have gone nowhere [3], we add subdomain support which allows a user
to simply set the server.route.subdomain value which will be then used
to construct the FQDN by adding the ingress cluster DNS domain. (E.g.
server.route.subdomain: foo will generate the FQDN "foo.apps.mycluster.com")

An additional reason for this change is that helm does not currently
work when setting 'null' values when using subcharts [4].

The status quo of having a default value in server.route.host has not
been changed and setting a subdomain will take precedence over the host
value.

Tested successfully on a 4.11 OCP cluster (mycluster.com) with the
following values:

---
global:
  openshift: true

injector:
  enabled: false
ui:
  enabled: true
  serviceType: "LoadBalancer"
server:
  route:
    enabled: true
    subdomain: "foobar"
    tls:
      termination: "edge"
  image:
    repository: "registry.connect.redhat.com/hashicorp/vault"
    tag: "1.11.2-ubi"

and correctly obtained a route that pointed to foobar.apps.mycluster.com

[1] https://docs.openshift.com/container-platform/4.6/rest_api/network_apis/route-route-openshift-io-v1.html
[2] kubernetes/kubernetes#44954
[3] https://docs.google.com/document/d/1F__vEKeI41P7PPUCMM9PVPYY34pyrvQI5rbTJVnS5c4/edit
[4] helm/helm#9136

This change adds route subdomain support (documented at [1]). One of the
reasons for adding this is that setting a subdomain requires no
knowledge at all of the global ingress domain of the cluster.
Since kubernetes has no concept of cluster name [2] and proposals to
change that have gone nowhere [3], we add subdomain support which allows a user
to simply set the server.route.subdomain value which will be then used
to construct the FQDN by adding the ingress cluster DNS domain. (E.g.
server.route.subdomain: foo will generate the FQDN "foo.apps.mycluster.com")

An additional reason for this change is that helm does not currently
work when setting 'null' values when using subcharts [4].

The status quo of having a default value in server.route.host has not
been changed and setting a subdomain will take precedence over the host
value.

Tested successfully on a 4.11 OCP cluster (mycluster.com) with the
following values:
---
global:
  openshift: true

injector:
  enabled: false
ui:
  enabled: true
  serviceType: "LoadBalancer"
server:
  route:
    enabled: true
    subdomain: "foobar"
    tls:
      termination: "edge"
  image:
    repository: "registry.connect.redhat.com/hashicorp/vault"
    tag: "1.11.2-ubi"

and correctly obtained a route that pointed to foobar.apps.mycluster.com

[1] https://docs.openshift.com/container-platform/4.6/rest_api/network_apis/route-route-openshift-io-v1.html
[2] kubernetes/kubernetes#44954
[3] https://docs.google.com/document/d/1F__vEKeI41P7PPUCMM9PVPYY34pyrvQI5rbTJVnS5c4/edit
[4] helm/helm#9136
@heatherezell heatherezell added the enhancement New feature or request label Aug 30, 2022
@mbaldessari
Copy link
Contributor Author

Now that https://www.github.com/helm/helm/issues/9136 is fixed, I think this is less interesting. Closing.

@mbaldessari mbaldessari closed this Feb 8, 2024
@mbaldessari mbaldessari deleted the subdomain branch February 8, 2024 10:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants