Skip to content

Commit

Permalink
add proxy inherit for direct insights post
Browse files Browse the repository at this point in the history
  • Loading branch information
aschmid13 authored Mar 24, 2020
1 parent 7d1a06b commit 4d58ead
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/outputs/http.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ func postRequest(url string, key string, data []byte) error {

load.Logrus.Debugf("http: insights - bytes %d events %d", len(zlibCompressedPayload.Bytes()), len(load.Entity.Metrics))

tr := &http.Transport{IdleConnTimeout: 15 * time.Second}
tr := &http.Transport{IdleConnTimeout: 15 * time.Second, Proxy: http.ProxyFromEnvironment}
client := &http.Client{Transport: tr}
req, err := http.NewRequest(http.MethodPost, url, bytes.NewBuffer(zlibCompressedPayload.Bytes()))
if err != nil {
Expand Down

0 comments on commit 4d58ead

Please sign in to comment.