Skip to content

feat: add Gateway API HTTPRoute support for AIO, Admin, Backend, and … - #67

Open
Nurielevi wants to merge 4 commits into
hoppscotch:mainfrom
Nurielevi:add-httproute-support
Open

feat: add Gateway API HTTPRoute support for AIO, Admin, Backend, and …#67
Nurielevi wants to merge 4 commits into
hoppscotch:mainfrom
Nurielevi:add-httproute-support

Conversation

@Nurielevi

Copy link
Copy Markdown

…Frontend components

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds Gateway API HTTPRoute support to the Hoppscotch Helm chart so AIO and distributed deployments (Frontend/Backend/Admin) can be exposed via a Gateway instead of (or in addition to) Ingress, including base-URL generation from HTTPRoute hostnames.

Changes:

  • Introduces per-component httpRoute values (enablement, parentRefs, hostnames, tls hint, annotations, rules).
  • Adds HTTPRoute templates for AIO, Frontend, Backend, and Admin components.
  • Updates frontend/backend/admin base URL helpers to fall back from Ingress to HTTPRoute-derived URLs; adds helm-unittest coverage for the new templates.

Reviewed changes

Copilot reviewed 13 out of 13 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
charts/hoppscotch/values.yaml Adds new httpRoute configuration blocks for AIO/Frontend/Backend/Admin.
charts/hoppscotch/templates/aio/httproute.yaml Renders an AIO HTTPRoute when in aio mode and enabled.
charts/hoppscotch/templates/frontend/httproute.yaml Renders a Frontend HTTPRoute when in distributed mode and enabled.
charts/hoppscotch/templates/backend/httproute.yaml Renders a Backend HTTPRoute when in distributed mode and enabled.
charts/hoppscotch/templates/admin/httproute.yaml Renders an Admin HTTPRoute when in distributed mode and enabled.
charts/hoppscotch/templates/_helpers.tpl Adds hoppscotch.httpRouteBaseUrl helper for URL generation from HTTPRoute hostnames.
charts/hoppscotch/templates/_frontend.tpl Adds HTTPRoute fallback when generating frontend base URL.
charts/hoppscotch/templates/_backend.tpl Adds HTTPRoute fallback when generating backend base URL.
charts/hoppscotch/templates/_admin.tpl Adds HTTPRoute fallback when generating admin base URL.
charts/hoppscotch/tests/aio_httproute_test.yaml Unit tests for AIO HTTPRoute rendering and rule behavior.
charts/hoppscotch/tests/frontend_httproute_test.yaml Unit tests for Frontend HTTPRoute rendering and fields.
charts/hoppscotch/tests/backend_httproute_test.yaml Unit tests for Backend HTTPRoute rendering and fields.
charts/hoppscotch/tests/admin_httproute_test.yaml Unit tests for Admin HTTPRoute rendering and fields.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +95 to +98
matches:
- path:
type: PathPrefix
value: /
Comment on lines +95 to +98
matches:
- path:
type: PathPrefix
value: /
Comment on lines +95 to +98
matches:
- path:
type: PathPrefix
value: /
Comment on lines 5 to 8
{{- if eq .Values.deploymentMode "aio" -}}
{{- $baseUrl := (include "hoppscotch.ingressBaseUrl" .Values.aio.ingress) -}}
{{- if not $baseUrl -}}{{- $baseUrl = (include "hoppscotch.httpRouteBaseUrl" .Values.aio.httpRoute) -}}{{- end -}}
{{- .Values.hoppscotch.frontend.enableSubpathBasedAccess | ternary (printf "%s/backend" $baseUrl) $baseUrl -}}
Comment on lines 5 to 8
{{- if eq .Values.deploymentMode "aio" -}}
{{- $baseUrl := (include "hoppscotch.ingressBaseUrl" .Values.aio.ingress) -}}
{{- if not $baseUrl -}}{{- $baseUrl = (include "hoppscotch.httpRouteBaseUrl" .Values.aio.httpRoute) -}}{{- end -}}
{{- .Values.hoppscotch.frontend.enableSubpathBasedAccess | ternary (printf "%s/admin" $baseUrl) $baseUrl -}}
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.

2 participants