Skip to content
This repository has been archived by the owner on Aug 30, 2019. It is now read-only.

writer: inherit and use "skip_ssl_validation" setting from Agent v{5,6} #395

Merged
merged 1 commit into from
Mar 12, 2018

Conversation

gbbr
Copy link
Contributor

@gbbr gbbr commented Mar 9, 2018

This should permit use-cases of running the agent behind a proxy such as haproxy, using the skip_ssl_validation: true setting in the config file.

@gbbr gbbr force-pushed the gbbr/ssl-skip-verify branch from 30a51d8 to 6c18533 Compare March 9, 2018 12:57
HostName string `yaml:"hostname"`
LogLevel string `yaml:"log_level"`
Proxy proxy `yaml:"proxy"`
SkipSSLValidation string `yaml:"skip_ssl_validation"`

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You should make it a *bool (like traceAgent.Enabled) so that you don't have to test manually yes, true, 1, ...

@gbbr gbbr force-pushed the gbbr/ssl-skip-verify branch from 6c18533 to a7ac6e7 Compare March 12, 2018 08:43
@gbbr
Copy link
Contributor Author

gbbr commented Mar 12, 2018

@LotharSee done. PTAL.

@@ -67,6 +67,13 @@ func mergeIniConfig(c *AgentConfig, conf *File) error {
} else if pURL != nil {
c.ProxyURL = pURL
}

switch m.Key("skip_ssl_validation").MustString("") {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This package also has a Bool method, but I wasn't sure whether to use it or not. I chose not to, because it wasn't used elsewhere either.

Copy link

@LotharSee LotharSee left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@gbbr gbbr merged commit 772af81 into master Mar 12, 2018
@gbbr gbbr deleted the gbbr/ssl-skip-verify branch March 12, 2018 12:03
@palazzem palazzem added the core label Mar 19, 2018
@palazzem palazzem added this to the 6.1.0 milestone Mar 19, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants