diff options
author | Byron Jones <glob@mozilla.com> | 2015-11-30 06:40:37 +0100 |
---|---|---|
committer | Byron Jones <glob@mozilla.com> | 2015-11-30 06:40:37 +0100 |
commit | 36283093128fc1f32d3562418f00c2763269cb11 (patch) | |
tree | 0177e9f2d000c3728bd3930f854a7fbdba3bd3fe | |
parent | 4e97b5b50641a9c5f450d5b75bd03e7767a0ef84 (diff) | |
download | bugzilla-36283093128fc1f32d3562418f00c2763269cb11.tar.gz bugzilla-36283093128fc1f32d3562418f00c2763269cb11.tar.xz |
Bug 1228910 - sentry.pl doesn't use the dc-proxy
-rwxr-xr-x | sentry.pl | 7 |
1 files changed, 6 insertions, 1 deletions
@@ -42,6 +42,11 @@ my $uri = URI->new(Bugzilla->params->{sentry_uri}); my $header = build_header($uri); exit(1) unless $header; +my $ua = LWP::UserAgent->new(timeout => 10); +if (my $proxy_url = Bugzilla->params->{proxy_url}) { + $ua->proxy(['http', 'https'], $proxy_url); +} + flock(DATA, LOCK_EX); foreach my $file (glob(bz_locations()->{error_reports} . '/*.dump')) { eval { @@ -82,7 +87,7 @@ sub send_file { # and post to sentry my $request = POST $uri->canonical, %$header, Content => $message; - my $response = LWP::UserAgent->new(timeout => 10)->request($request); + my $response = $ua->request($request); } __DATA__ |