Environments
Environments let you separate events from different deployment contexts. Production, staging, local development. So you can focus on what matters.
Setting the environment
Configure the environment in your SDK. It is sent with every event and stored as a tag.
Laravel
SENTRY_ENVIRONMENT=production
Or in config/sentry.php:
'environment' => env('APP_ENV', 'production'),
JavaScript
Sentry.init({
dsn: 'https://your-key@your-hostname.tindra.sh/1',
environment: 'production',
});
Python
sentry_sdk.init(
dsn="https://your-key@your-hostname.tindra.sh/1",
environment="production",
)
Filtering by environment
Use the environment selector at the top of the dashboard to scope all views to a specific environment. The issues list, event counts, and performance data all update to reflect the selected environment.
Recommended setup
Use a consistent naming convention across all your projects:
| Value | When to use |
|---|---|
production |
Live traffic, real users |
staging |
Pre-release testing, internal QA |
development |
Local dev machines |
Avoid sending local development errors to Tindra unless you intentionally want to capture them.
Disabling SDK in development
For Laravel, set SENTRY_LARAVEL_DSN only in production and staging environments. Leave it unset locally so the SDK stays disabled.
For JavaScript, gate initialization on the environment:
if (process.env.NODE_ENV === 'production') {
Sentry.init({ dsn: '...' });
}