self-hosting using a nexus proxy on air-gapped box
Describe the bug
CLI supabase bin is hardcorded to call public.ecr.aws.
In a linux ubuntu box with no direct internet access, where it only has access to a sonatype nexus server.
To Reproduce
Steps to reproduce the behavior, please provide code snippets or a repository:
- Ensure the nexus repo is setup . This is added to the registry of the .npmrc config file. Also ensure the nexus repo has all the libraries/folders that mirrors github.
registry=https://your-nexus-repo strict-ssl=false - Install supabase using npm(or pnpm) Make sure you ignore scripts as the postintall is also hardcoded to call github.
npm install supabase --ignore-scripts - Replace the hardcoded github.com value in
postinstall.jsto your-nexus-repo. - Rerun the npm install supabase. This time the postinstall.js will use the nexus.
- Run > supabase start
- supbase bin will still try to reach out to "https://public.ecr.aws/v2/"
Is there perhaps a env variable supabase bin can use ?
Screenshots
If applicable, add screenshots to help explain your problem.
System information
- OS: Ubuntu 22.4
- Browser (if applies) [e.g. chrome, safari]
- Version of supabase-js: 10.9.0
- Version of Node.js: v22.12.0
Additional context
Add any other context about the problem here.
Pretty sure it's not what you want exactly, but if it's of any urgency you can quickly change this line of code here and rebuild the cli
// Defaults to Supabase public ECR for faster image pull
const defaultRegistry = "public.ecr.aws"
Here's what I got with a dummy Nexus value, I assume this is the functionality you're looking for
➜ cli git:(develop) ✗ ./supabase-test start
Starting database... failed to pull docker image: Error response from daemon: pull access denied for your-nexus-repo/supabase/postgres, repository does not exist or may require 'docker login': denied: requested access to the resource is denied Retrying after 4s: your-nexus-repo/supabase/postgres:17.6.1.021
Moved over from supabase repo.
@ahadda5 you can set the environment variable SUPABASE_INTERNAL_IMAGE_REGISTRY to pull images from your local registry. For instance:
SUPABASE_INTERNAL_IMAGE_REGISTRY=your-nexus-repo supabase start --debug
Hi all, We’re going to close this one due to inactivity. Please feel free to reopen if you’re still having issues here or open a new issue.