There are two recommended ways to deploy Sourcegraph:
But what if your organization wants a multi-machine deployment without using Kubernetes? What if you use a different container management platform, for example? This project aims to solve that, by providing a pure-Docker deployment option.
The goal is that anyone using a container management platform other than Kubernetes (Netflix's Titus, Apache's Mesos, etc.) would be able to use this repository as a reference for how to deploy Sourcegraph.
First clone the repository, then:
Visit http://localhost:3080 to visit the running Sourcegraph instance!
To understand the system topology:
deploy.shto get an overview of services.
deploy-*.sh) has documentation inline indicating:
Every service (
deploy-*.sh) documents inline what the system requirements are (CPU/Memory/Disk allocation). For example, the frontend service.
To scale the cluster deployment, you will need to:
symbolsservices as desired.
frontend-internalto communicate with the new instances.
This deployment comes with metrics and tracing built-in. See metrics and tracing for details.
"ssh". You may still need to configure an access token or other codehost authentication method in order for Sourcegraph to discover your repositories.
Alternatively, you may use the
OTHER codehost type under External services, which allows you to directly specify Git repository URLs for cloning.
gitserverinstances with your SSH / Git configuration (usually just
.ssh/known_hosts-- but you can also provide other files like
.gitconfig, etc. if needed) by mounting it into the
sourcegraphusers home directory in the
gitservercontainers. For example, by adding the following flag:
All future Git cloning operations will use the credentials configured there.
If you wish, you can test that cloning with your configuration is working by performing the clone in a gitserver container shell, e.g. first acquire shell access:
$ docker exec -it gitserver-0 sh
Then try cloning the repository:
$ git clone ssh://email@example.com/my/repo /tmp/my-repo
By leveraging automation, code generation, and machine learning, we are capable of delivering secure, stable, and change-embracing software. Through research and education, we push the boundaries of technology forward.
© 2020 Protoku. All rights reserved.