Replies: 2 comments 1 reply
-
You can exclude starting unnecessary containers using the https://supabase.com/docs/reference/cli/supabase-start?example=supabase-start-without-studio It reduces my startup time slightly, but still takes a few minutes. Would be great to be able to improve it more |
Beta Was this translation helpful? Give feedback.
0 replies
-
I know it's not answering the question, but starting it concurrently works, i.e. like this: - name: Start Supabase in background
run: |
supabase start --exclude realtime,storage-api,imgproxy,inbucket,studio,edge-runtime &
echo "Supabase starting in background..."
... all the build steps here
- name: Wait for Supabase to be ready
run: |
timeout=180
counter=0
until curl -s http://localhost:54321/rest/v1/ >/dev/null; do
if [ $counter -gt $timeout ]; then
echo "Timed out waiting for Supabase"
exit 1
fi
echo "Waiting for Supabase to be ready..."
sleep 1
counter=$((counter + 1))
done
echo "Supabase is ready!" and in my case it takes roughly the same time as typechecking and build steps of the app so I'm no longer blocked by it |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hey, I'm currently working on a project where I'm using Github Actions for CI/CD with Supabase. It's working well, but one of the jobs before deploying migrations to production is to do e2e testing using a supabase instance that is spun up in the action runner. I'm doing this by setting up the CLI using the provided action and then running
supabase start
. This is very slow though and takes the runtime for the action from 40-60 seconds up to 5 minutes.I see that a lot of services are being started and their images probably being pulled. Some of them, like studio and postgrest, aren't required for the e2e-tests, but I see no way of disabling them. I'm not good with Github Actions and Docker so I'd like to know if there are strategies to speed up the
supabase start
command in a CI-context.Beta Was this translation helpful? Give feedback.
All reactions