Skip to content

Commit

Permalink
Update docs on running getsentry locally (#11428)
Browse files Browse the repository at this point in the history
* update docs
* revert formatting change
---------
  • Loading branch information
vgrozdanic authored Sep 26, 2024
1 parent baff297 commit 672d356
Showing 1 changed file with 7 additions and 8 deletions.
15 changes: 7 additions & 8 deletions develop-docs/development/environment/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,12 @@ After installation you should be able to run `devenv bootstrap` which will guide

When you're done with setup, you'll want to also review the <Link to="/development/workflow/">development workflow</Link>.


## Keeping your environment up-to-date

Simply run `devenv sync` inside of your sentry or getsentry repo.

NOTE: After running `devenv sync` you may need to restart your terminal to continue.


## Running the Development Server

The `devservices` ensure that you have all the services required for local development running. See the [devservices docs](/services/devservices/) for more information on managing services.
Expand Down Expand Up @@ -108,6 +106,8 @@ sentry devservices up snuba

See also: <Link to="/sentry-vs-getsentry/">Sentry vs Getsentry</Link>

Before running `getsentry`, you might need to run `devenv sync` inside the `getsentry` directory if you have previously run `sentry` locally, as there might be differences between the environments.

Just like running `sentry` (see above), you can start the `devservices` using the following command in the `getsentry` folder:

```shell
Expand All @@ -122,26 +122,24 @@ getsentry devserver --workers

**Note**: You **cannot** have both sentry and getsentry devserver running at the same time.

After the server warms up for a little while, you must access it
at [http://dev.getsentry.net:8000](http://dev.getsentry.net:8000/).
Using localhost doesn't work.
After the server warms up, access it at [http://dev.getsentry.net:8000](http://dev.getsentry.net:8000/). Using localhost won't work. Note that the **http** protocol is used, not **https**. If you encounter a certificate error while accessing it locally, it might be because your browser has remembered that `dev.getsentry.net` previously used the https protocol (possibly while running `yarn dev-ui`) and is now redirecting all http requests to https. To resolve this, open the site in an **incognito window** of your browser.

If you need to overwrite configuration options for your local
environment, you can create `getsentry/conf/settings/devlocal.py` and put the
configuration option overrides there. This module will be automatically imported
by `dev.py` if it exists.

To enable the ingest workers, follow the steps described <Link to="#ingestion-pipeline-relay">here</Link> and run

```shell
getsentry devserver --workers --ingest
```


## Running siloed instances

By default `sentry devserver` will run a monolith mode application server. You can also run ``devserver`` with siloed application instances. Before you do, you need to <Link to="/database-migrations/#cloning-a-monolith-database">create split silo databases</Link>.
By default `sentry devserver` will run a monolith mode application server. You can also run `devserver` with siloed application instances. Before you do, you need to <Link to="/database-migrations/#cloning-a-monolith-database">create split silo databases</Link>.

The devserver command supports `--silo` option that lets you create siloed instances. Any workers, consumers, or celery-beat processes will be started with the same silo mode.
The devserver command supports `--silo` option that lets you create siloed instances. Any workers, consumers, or celery-beat processes will be started with the same silo mode.

```shell
# Start control silo servers
Expand All @@ -150,6 +148,7 @@ sentry devserver --silo=control --celery-beat --workers
# Start region silo servers
sentry devserver --silo=region --celery-beat --workers --ingest
```

Siloed servers have the following port assignments:

- 8000 - Webpack
Expand Down

0 comments on commit 672d356

Please sign in to comment.