Skip to content

Commit

Permalink
Add Disable SSL and Force Path Style options.
Browse files Browse the repository at this point in the history
  • Loading branch information
allapospelova committed Jul 2, 2019
1 parent 83b59d6 commit 14ef3eb
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions s3_exporter.go
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,8 @@ func main() {
metricsPath = app.Flag("web.metrics-path", "Path under which to expose metrics").Default("/metrics").String()
probePath = app.Flag("web.probe-path", "Path under which to expose the probe endpoint").Default("/probe").String()
endpointURL = app.Flag("s3.endpoint-url", "Custom endpoint URL").Default("").String()
disableSSL = app.Flag("s3.disable-ssl", "Custom disable SSL").Bool()
forcePathStyle = app.Flag("s3.force-path-style", "Custom force path style").Bool()
)

log.AddFlags(kingpin.CommandLine)
Expand All @@ -169,6 +171,9 @@ func main() {
cfg.WithEndpoint(*endpointURL)
}

cfg.WithDisableSSL(*disableSSL)
cfg.WithS3ForcePathStyle(*forcePathStyle)

svc := s3.New(sess, cfg)

log.Infoln("Starting "+namespace+"_exporter", version.Info())
Expand Down

0 comments on commit 14ef3eb

Please sign in to comment.