| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [View Raw Code] [Original HTTPS Page] |
| title | Install Sourcegraph via Shell Script |
|---|
Following these docs will launch a pre-configured single node Sourcegraph instance via shell script.
The script can be run on the following distros.
As it is impossible to test all possible deployment environments it is possible albeit unlikely to encounter an error. We highly suggest using one of our curated Machine Images if possible.
Determine the instance type required to support the number of users and repositories you have using this table. If you fall between two sizes, choose the larger of the two.
For example, if you have 8,000 users with 80,000 repositories, your instance size would be L. If you have 1,000 users with 80,000 repositories, you should go with size M.
| XS | S | M | L | XL | |
|---|---|---|---|---|---|
| Users | <= 500 | <= 1,000 | <= 5,000 | <= 10,000 | <= 20,000 |
| Repositories | <= 5,000 | <= 10,000 | <= 50,000 | <= 100,000 | <= 250,000 |
| Recommended vCPU / RAM | 8 / 32 GiB | 16 / 64 GiB | 32 / 128 GiB | 48 / 192 GiB | 96 / 384 GiB |
| Minimum vCPU / RAM | 8 / 32 GiB | 8 / 32 GiB | 16 / 64 GiB | 32 / 128 GiB | 48 / 192 GiB |
Before running the install script please ensure ensure the target machine meets the following prerequisites.
IMPORTANT For optimal performance both disks should be backed by SSDs or equivalently fast storage.
The script accepts the following parameters:
-d <device>
The data disk where Sourcegraph persistent data should be stored e.g. -d /dev/sdb
The script will format the disk if it has not been formatted already. If you choose to format and mount the disk yourself it must be mounted to /mnt/data MUST be a separate disk than e.g. the base OS for upgrades.
-s <size>
The Instance Size to use. Defaults to XS
-v <version>
The Sourcegraph version to deploy. Defaults to the latest version
curl -sfL https://raw.githubusercontent.com/sourcegraph/deploy/main/install/scripts/k3s/install.sh | bash -s -- <args>NOTE: Please allow up to ~5 minutes for Sourcegraph to initialize
Sourcegraph will be available on ports 80 and 443 (using a self signed certificate).
We recommend deploying your own reverse proxy to terminate TLS connections with a properly signed certificate.
IMPORTANT Back up your volumes before each upgrade
Please refer to the upgrade procedure above if you wish to rollback your instance.
We strongly recommend taking snaphots of the data disk on an automatic, scheduled basis.
| Back | FazBrowse Home | New Git URL |