When '%' in my uri ,the marathon_exporter can't running. - #26
Conversation
| -marathon.uri string | ||
| URI of Marathon (default "http://marathon.mesos:8080") | ||
| Note: Supply HTTP Basic Auth (i.e. user:password@example.com) | ||
| If you URI inclube '%' ,you should used marathon.username and marathon.password |
There was a problem hiding this comment.
Typo fixes: "if your URI include '%', you should use...."
Also, about your PR, you have the issue when you have % in your password for instance right?
| -marathon.username string | ||
| marathon author username ,(default "") | ||
| -marathon.password string | ||
| marathon author password ,(default "") |
There was a problem hiding this comment.
Please remove both unnecessary ','
Also, change 'author' -> 'user' to be clearer for the user.
| @@ -0,0 +1,19 @@ | |||
| module marathon_exporter | |||
There was a problem hiding this comment.
Can you propose a different PR to switch to go modules please?
| } | ||
|
|
||
| response, err := client.Get(fmt.Sprintf("%v/%s", s.uri, path)) | ||
| //response, err := client.Get(fmt.Sprintf("%v/%s", s.uri, path)) |
There was a problem hiding this comment.
you can remove the comment if we don't use it anymore
| config.HTTPBasicAuthUser = uri.User.Username() | ||
| } | ||
| } | ||
| config.HTTPBasicAuthUser = *marathonUserName |
There was a problem hiding this comment.
So, user is not able to specify its marathon user and password in the URL anymore? It would be ncie to be able to do both for retro compatibility
|
I tested with your branch, and even with your last commits, the scrapper does not authenticate properly when using the user/pass provided in the URI and can't fetch all metrics. |
oh, I used marathon v1.14.x ,it not have prometheus exporter URL path. |
When '%' in my uri ,the marathon_exporter can't running.
So , I fix the bug.