Skip to content

The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.

docs: self-hosting - add alternative command to make checkout faster (#23701)

cyluss278023e39fe5
diff --git a/apps/docs/content/guides/self-hosting/docker.mdx b/apps/docs/content/guides/self-hosting/docker.mdx
index e2aa7dfa756..52870807baa 100644
--- a/apps/docs/content/guides/self-hosting/docker.mdx
+++ b/apps/docs/content/guides/self-hosting/docker.mdx
@@ -17,6 +17,15 @@ You need the following installed in your system: [Git](https://git-scm.com/downl
Follow these steps to start Supabase locally:
+<Tabs
+ scrollable
+ size="small"
+ type="general"
+ defaultActiveId="general"
+ queryGroup="running-supabase"
+>
+<TabPanel id="general" label="General">
+
```sh
# Get the code
git clone --depth 1 https://github.com/supabase/supabase
@@ -34,6 +43,31 @@ docker compose pull
docker compose up -d
```
+</TabPanel>
+<TabPanel id="advanced" label="Advanced">
+
+```sh
+# Get the code using git sparse checkout
+git clone --filter=blob:none --no-checkout https://github.com/supabase/supabase
+cd supabase
+git sparse-checkout set --cone docker && git checkout master
+
+# Go to the docker folder
+cd docker
+
+# Copy the fake env vars
+cp .env.example .env
+
+# Pull the latest images
+docker compose pull
+
+# Start the services (in detached mode)
+docker compose up -d
+```
+
+</TabPanel>
+</Tabs>
+
After all the services have started you can see them running in the background:
```sh