Skip to content

Commit

Permalink
use when@prod for sentry (#1420)
Browse files Browse the repository at this point in the history
Co-authored-by: Robin Lehrmann <robin.lehrmann@developer.nrw>
  • Loading branch information
nicolas-grekas and robinlehrmann authored Jul 12, 2022
1 parent 7d26203 commit f0aa0d8
Show file tree
Hide file tree
Showing 3 changed files with 47 additions and 13 deletions.
26 changes: 13 additions & 13 deletions sentry/sentry-symfony/3.0/config/packages/prod/sentry.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,18 @@ sentry:
- Symfony\Component\HttpKernel\Exception\NotFoundHttpException
- Symfony\Component\Security\Core\Exception\AccessDeniedException

# If you are using Monolog, you also need these additional configuration and services to log the errors correctly:
# https://docs.sentry.io/platforms/php/guides/symfony/#monolog-integration
# register_error_listener: false
# If you are using Monolog, you also need these additional configuration and services to log the errors correctly:
# https://docs.sentry.io/platforms/php/guides/symfony/#monolog-integration
# register_error_listener: false

# monolog:
# handlers:
# sentry:
# type: service
# id: Sentry\Monolog\Handler
# monolog:
# handlers:
# sentry:
# type: service
# id: Sentry\Monolog\Handler

# services:
# Sentry\Monolog\Handler:
# arguments:
# $hub: '@Sentry\State\HubInterface'
# $level: !php/const Monolog\Logger::ERROR
# services:
# Sentry\Monolog\Handler:
# arguments:
# $hub: '@Sentry\State\HubInterface'
# $level: !php/const Monolog\Logger::ERROR
20 changes: 20 additions & 0 deletions sentry/sentry-symfony/4.0/config/packages/sentry.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
when@prod:
sentry:
dsn: '%env(SENTRY_DSN)%'

# If you are using Monolog, you also need these additional configuration and services to log the errors correctly:
# https://docs.sentry.io/platforms/php/guides/symfony/#monolog-integration
# register_error_listener: false

# monolog:
# handlers:
# sentry:
# type: service
# id: Sentry\Monolog\Handler

# services:
# Sentry\Monolog\Handler:
# arguments:
# $hub: '@Sentry\State\HubInterface'
# $level: !php/const Monolog\Logger::ERROR
# $bubble: false
14 changes: 14 additions & 0 deletions sentry/sentry-symfony/4.0/manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"bundles": {
"Sentry\\SentryBundle\\SentryBundle": ["prod"]
},
"copy-from-recipe": {
"config/": "%CONFIG_DIR%/"
},
"env": {
"SENTRY_DSN": ""
},
"conflict": {
"symfony/framework-bundle": "<5.4"
}
}

0 comments on commit f0aa0d8

Please sign in to comment.