@ -70,18 +70,14 @@ const (
authMethodManagedIdentity = "ManagedIdentity"
)
var (
userAgent = fmt . Sprintf ( "Prometheus/%s" , version . Version )
// DefaultSDConfig is the default Azure SD configuration.
DefaultSDConfig = SDConfig {
Port : 80 ,
RefreshInterval : model . Duration ( 5 * time . Minute ) ,
Environment : "AzurePublicCloud" ,
AuthenticationMethod : authMethodOAuth ,
HTTPClientConfig : config_util . DefaultHTTPClientConfig ,
}
)
// DefaultSDConfig is the default Azure SD configuration.
var DefaultSDConfig = SDConfig {
Port : 80 ,
RefreshInterval : model . Duration ( 5 * time . Minute ) ,
Environment : "AzurePublicCloud" ,
AuthenticationMethod : authMethodOAuth ,
HTTPClientConfig : config_util . DefaultHTTPClientConfig ,
}
var environments = map [ string ] cloud . Configuration {
"AZURECHINACLOUD" : cloud . AzureChina ,
@ -244,7 +240,7 @@ func (d *Discovery) createAzureClient() (client, error) {
c . logger = d . logger
telemetry := policy . TelemetryOptions {
ApplicationID : userAgent ,
ApplicationID : version . Promethe usUs erAgent( ) ,
}
credential , err := newCredential ( * d . cfg , policy . ClientOptions {