Skip to content

Commit 108e738

Browse files
authored
Merge pull request #192 from getsentry/add-http-proxy-option
Add http proxy option
2 parents e377ccb + 9422e53 commit 108e738

File tree

4 files changed

+7
-1
lines changed

4 files changed

+7
-1
lines changed

src/DependencyInjection/Configuration.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,8 @@ public function getConfigTreeBuilder()
7171
->defaultValue($defaultValues->getExcludedExceptions())
7272
->scalarPrototype()->end()
7373
->end()
74+
->scalarNode('http_proxy')
75+
->end()
7476
// TODO -- integrations
7577
->scalarNode('logger')
7678
->end()

src/DependencyInjection/SentryExtension.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@ private function passConfigurationToOptions(ContainerBuilder $container, array $
5555
'enable_compression',
5656
'environment',
5757
'excluded_exceptions',
58+
'http_proxy',
5859
'logger',
5960
'max_breadcrumbs',
6061
'prefixes',

test/DependencyInjection/ConfigurationTest.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111

1212
class ConfigurationTest extends TestCase
1313
{
14-
public const SUPPORTED_SENTRY_OPTIONS_COUNT = 18;
14+
public const SUPPORTED_SENTRY_OPTIONS_COUNT = 19;
1515

1616
public function testDataProviderIsMappingTheRightNumberOfOptions(): void
1717
{
@@ -91,6 +91,7 @@ public function optionValuesProvider(): array
9191
['enable_compression', false],
9292
['environment', 'staging'],
9393
['error_types', E_ALL],
94+
['http_proxy', '1.2.3.4:5678'],
9495
['in_app_exclude', ['some/path']],
9596
['excluded_exceptions', [\Throwable::class]],
9697
['logger', 'some-logger'],
@@ -132,6 +133,7 @@ public function invalidValuesProvider(): array
132133
['enable_compression', 'string'],
133134
['environment', ''],
134135
['error_types', []],
136+
['http_proxy', []],
135137
['in_app_exclude', 'some/single/path'],
136138
['excluded_exceptions', 'some-string'],
137139
['logger', []],

test/DependencyInjection/SentryExtensionTest.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,7 @@ public function optionsValueProvider(): array
9494
['error_types', E_ALL & ~E_NOTICE],
9595
['in_app_exclude', ['/some/path'], 'getInAppExcludedPaths'],
9696
['excluded_exceptions', [\Throwable::class]],
97+
['http_proxy', '1.2.3.4'],
9798
['logger', 'sentry-logger'],
9899
['max_breadcrumbs', 15],
99100
['prefixes', ['/some/path/prefix/']],

0 commit comments

Comments
 (0)