Skip to content

Feat: Add Supabase - Deploy Edge Function community step template#1688

Merged
benPearce1 merged 3 commits into
OctopusDeploy:masterfrom
itsmebenwalker:bw/supabase-deploy-edge-func
Jun 2, 2026
Merged

Feat: Add Supabase - Deploy Edge Function community step template#1688
benPearce1 merged 3 commits into
OctopusDeploy:masterfrom
itsmebenwalker:bw/supabase-deploy-edge-func

Conversation

@itsmebenwalker
Copy link
Copy Markdown
Contributor

@itsmebenwalker itsmebenwalker commented Jun 2, 2026

Background

Supabase is an open-source alternative to Firebase built on PostgreSQL. It includes a managed database, authentication, storage, realtime subscriptions, and Edge Functions-globally distributed TypeScript/Deno serverless functions.

The rise of AI-assisted development tools such as Cursor, Windsurf, and Claude Code has also led to broader adoption of Supabase. Its generated SDKs, built-in APIs, and CLI tooling make it easy to stand up and evolve a backend, which works well for teams building applications with AI coding tools. Many people are now deploying applications built with Supabase, and Edge Functions are increasingly where application logic is implemented. This presents a strong opportunity for Octopus to further support and streamline these deployment workflows.

The Octopus Library already has a Supabase - Run Migrations step template for pushing database schema changes. This PR adds the missing companion step: deploying Edge Functions.

Sample repository:

octopus-community-step-temp-supabase

Results

Adds a new community step template Supabase - Deploy Edge Function (step-templates/supabase-deploy-edge-function.json) that:

  • Installs the Supabase CLI on the worker if not already present (Linux binary from GitHub releases, Homebrew on macOS), with optional version pinning
  • Authenticates via the SUPABASE_ACCESS_TOKEN environment variable - no interactive login required, safe for CI/CD workers
  • Resolves the working directory from the extracted package (#{Octopus.Action.Package[supabase-migrations].ExtractedPath}) with a fallback to the current directory, matching the pattern used by the existing Supabase - Run Migrations step
  • Deploys a named function (supabase functions deploy <name> --project-ref ... --workdir ...) or all functions in the package (leave Function Name empty to deploy all)
  • Optionally disables JWT verification (--no-verify-jwt) for public functions
  • Optionally accepts a custom import map path (--import-map)
  • Runs an optional post-deploy smoke test: GET the function URL and assert a non-5xx response - a 401 is a pass (expected when JWT verification is enabled)

Parameters

Parameter Type Required
SupabaseProjectRef String Yes
SupabaseAccessToken Sensitive Yes
SupabaseFunctionName String No - leave empty to deploy all functions
SupabaseVerifyJWT Checkbox No - default: enabled
SupabaseImportMapPath String No
SupabaseSmokeTest Checkbox No - default: off
SupabaseCliVersion String No - default: latest

Before

Deploying Supabase Edge Functions from an Octopus deployment required a custom Run a Script step, manually scripting the CLI install, authentication, and deploy command for each project.

After

A single reusable step template. Attach the package containing supabase/functions/, supply the project ref and access token, and the step handles the rest - including CLI installation on a clean worker.

Octopus task log

ServerTasks-2176.log.txt

Octopus step configuration

image image

Supabase dashboard - deployed functions

image image

Pre-requisites

  • Id is a GUID (c3e5a7f2-8b14-4d9c-a6e0-f1d2b3c4e5f6) and not all zeros
  • Version is 1 (new template)
  • Parameter names do not start with $
  • All parameter names are prefixed with Supabase to avoid clashing with user-defined project variables
  • LastModifiedBy is present (itsmebenwalker)
  • Category is supabase - existing category, no new logo or gulpfile.babel.js change required

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 2, 2026

Review this PR in Hyponome for a side-by-side diff of the step-template JSON and any embedded scripts.

@itsmebenwalker itsmebenwalker changed the title Bw/supabase deploy edge func Feat: Add Supabase - Deploy Edge Function community step template Jun 2, 2026
@benPearce1 benPearce1 merged commit cad0c82 into OctopusDeploy:master Jun 2, 2026
3 checks passed
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