supabase-kubernetes icon indicating copy to clipboard operation
supabase-kubernetes copied to clipboard

Kong configuration for functions-v1-all is hardcoded

Open guivin opened this issue 1 year ago • 1 comments

Bug report

Describe the bug

The url used in the Kong configuration for functions-v1-all is hardcoded in charts/supabase/templates/kong/config.yaml :

url: http://functions:{{ .Values.functions.service.port }}/

Should be :

 url: http://{{ include "supabase.functions.fullname" . }}:{{ .Values.functions.service.port }}/

To Reproduce

  1. Deploy the Helm with a name other than functions for the edge-function.
  2. Request you function through the Kong gateway : curl -X POST http://$IP:$PORT/functions/v1/ping
  3. Looking the Kong logs you will have a DNS resolution error meaning that the Kong gateway cannot find the functions

Set functions.fullnameOverride to functions in the values.yaml fixes temporary the issue.

Expected behavior

The internal DNS name of the functions should be dynamic to support prefixed resources by Helm

guivin avatar Oct 21 '24 16:10 guivin

This seems to be a duplicate of #61

joeldomke avatar Oct 22 '24 07:10 joeldomke