Skip to content

Conversation

@kallebysantos
Copy link
Member

What kind of change does this PR introduce?

Feature

What is the new behaviour?

Its allows Edge Functions Management API to use folder introspection and serve function metadata.
ref: supabase/supabase#40690, internal RFC

Additional context

screenshots image image

I'm keeping it very simple for now.
Please let me know if a more complex volume binding like this one is needed

binds := []string{}
for slug, fc := range functionsConfig {
if !fc.Enabled {
fmt.Fprintln(os.Stderr, "Skipped serving Function:", slug)
delete(functionsConfig, slug)
continue
}
modules, err := deploy.GetBindMounts(cwd, utils.FunctionsDir, "", fc.Entrypoint, fc.ImportMap, fsys)
if err != nil {
return nil, "", err
}
binds = append(binds, modules...)
fc.ImportMap = utils.ToDockerPath(fc.ImportMap)
fc.Entrypoint = utils.ToDockerPath(fc.Entrypoint)
functionsConfig[slug] = fc
for i, val := range fc.StaticFiles {
fc.StaticFiles[i] = utils.ToDockerPath(val)
}

cc @sweatybridge

@kallebysantos kallebysantos requested a review from a team as a code owner December 3, 2025 01:08
@kallebysantos kallebysantos force-pushed the feat-local-functions-studio-management-api branch from 4890a39 to 8764f93 Compare December 5, 2025 22:54
@sweatybridge sweatybridge merged commit f386e44 into supabase:develop Dec 23, 2025
9 of 11 checks passed
@coveralls
Copy link

Pull Request Test Coverage Report for Build 20454175367

Warning: This coverage report may be inaccurate.

This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.

Details

  • 30 of 42 (71.43%) changed or added relevant lines in 2 files are covered.
  • 7 unchanged lines in 2 files lost coverage.
  • Overall coverage increased (+0.02%) to 56.086%

Changes Missing Coverage Covered Lines Changed/Added Lines %
internal/start/start.go 28 40 70.0%
Files with Coverage Reduction New Missed Lines %
internal/start/start.go 2 65.3%
internal/gen/keys/keys.go 5 12.9%
Totals Coverage Status
Change from base Build 20453959894: 0.02%
Covered Lines: 6829
Relevant Lines: 12176

💛 - Coveralls

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