Skip to content

Commit b800b76

Browse files
docs
1 parent 6ff0d3a commit b800b76

File tree

1 file changed

+19
-25
lines changed

1 file changed

+19
-25
lines changed

docs/docs/deployment-guide.mdx

Lines changed: 19 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,24 @@ title: "Deployment guide"
44

55
import SupportedPlatforms from '/snippets/platform-support.mdx'
66

7-
The following guide will walk you through the steps to deploy Sourcebot on your own infrastructure. Sourcebot is distributed as a [single docker container](/docs/overview#architecture) that can be deployed to a k8s cluster, a VM, or any platform that supports docker.
7+
Sourcebot is distributed as a [single docker container](/docs/overview#architecture) that can be deployed to a k8s cluster, a VM, or any platform that supports docker. The following guide will walk you through the steps to deploy Sourcebot locally using [Docker compose](https://docs.docker.com/compose).
88

99

10-
<Note>Hit an issue? Please let us know on [GitHub](https://github.com/sourcebot-dev/sourcebot/issues/new/choose) or by [emailing us](mailto:team@sourcebot.dev).</Note>
10+
<Note>Hit an issue? Please let us know on [GitHub](https://github.com/sourcebot-dev/sourcebot/issues/new) or by [emailing us](mailto:team@sourcebot.dev).</Note>
11+
12+
## Walkthrough
13+
---
1114

1215
<Steps>
1316
<Step title="Requirements">
14-
- Docker -> use [Docker Desktop](https://www.docker.com/products/docker-desktop/) on Mac or Windows.
17+
- docker & docker compose -> use [Docker Desktop](https://www.docker.com/products/docker-desktop/) on Mac or Windows.
18+
</Step>
19+
<Step title="Obtain the Docker Compose file">
20+
Download the [docker-compose.yml](https://github.com/sourcebot-dev/sourcebot/blob/main/docker-compose.yml) file from the Sourcebot repository.
21+
22+
```bash wrap icon="terminal"
23+
curl -o docker-compose.yml https://raw.githubusercontent.com/sourcebot-dev/sourcebot/main/docker-compose.yml
24+
```
1525
</Step>
1626
<Step title="Create a config.json">
1727
Create a `config.json` file that tells Sourcebot which repositories to sync and index:
@@ -38,40 +48,24 @@ The following guide will walk you through the steps to deploy Sourcebot on your
3848
<Step title="Launch your instance">
3949
<Warning>If you're deploying Sourcebot behind a domain, you must set the [AUTH_URL](/docs/configuration/environment-variables) environment variable.</Warning>
4050

51+
Launch your Sourcebot instance:
4152

42-
In the same directory as `config.json`, run the following command to start your instance:
43-
44-
``` bash icon="terminal" Start the Sourcebot container
45-
docker run \
46-
-p 3000:3000 \
47-
--pull=always \
48-
--rm \
49-
-v $(pwd):/data \
50-
-e CONFIG_PATH=/data/config.json \
51-
--name sourcebot \
52-
ghcr.io/sourcebot-dev/sourcebot:latest
53+
```bash wrap icon="terminal"
54+
docker compose up -d
5355
```
54-
55-
<Accordion title="Details">
56-
**This command**:
57-
- pulls the latest version of the `sourcebot` docker image.
58-
- mounts the working directory to `/data` in the container to allow Sourcebot to persist data across restarts, and to access the `config.json`. In your local directory, you should see a `.sourcebot` folder created that contains all persistent data.
59-
- runs any pending database migrations.
60-
- starts up all services, including the webserver exposed on port 3000.
61-
- reads `config.json` and starts syncing.
62-
</Accordion>
63-
6456
</Step>
6557

6658
<Step title="Complete onboarding">
67-
Navigate to `http://localhost:3000` and complete the onboarding flow.
59+
Navigate to [http://localhost:3000](http://localhost:3000) and complete the onboarding flow.
6860
</Step>
6961

7062
<Step title="Done">
7163
You're all set! If you'd like to setup [Ask Sourcebot](/docs/features/ask/overview), configure a language model [provider](/docs/configuration/language-model-providers).
7264
</Step>
7365
</Steps>
7466

67+
Checkout the [configuration docs](/docs/configuration/environment-variables) to learn more about how to configure your deployment.
68+
7569
## Next steps
7670
---
7771

0 commit comments

Comments
 (0)