config: adapt unit tests

This commit is contained in:
Frederic Branczyk 2016-10-10 12:42:01 +02:00 committed by Fabian Reinartz
parent b24602f713
commit 2e18c81a00
4 changed files with 5 additions and 10 deletions

View file

@ -235,14 +235,12 @@ var expectedConf = &Config{
KubernetesSDConfigs: []*KubernetesSDConfig{ KubernetesSDConfigs: []*KubernetesSDConfig{
{ {
APIServers: []URL{kubernetesSDHostURL()}, APIServer: kubernetesSDHostURL(),
Role: KubernetesRoleEndpoint, Role: KubernetesRoleEndpoint,
BasicAuth: &BasicAuth{ BasicAuth: &BasicAuth{
Username: "myusername", Username: "myusername",
Password: "mypassword", Password: "mypassword",
}, },
RequestTimeout: model.Duration(10 * time.Second),
RetryInterval: model.Duration(1 * time.Second),
}, },
}, },
}, },

View file

@ -116,8 +116,7 @@ scrape_configs:
kubernetes_sd_configs: kubernetes_sd_configs:
- role: endpoint - role: endpoint
api_servers: api_server: 'https://localhost:1234'
- 'https://localhost:1234'
basic_auth: basic_auth:
username: 'myusername' username: 'myusername'

View file

@ -3,8 +3,7 @@ scrape_configs:
kubernetes_sd_configs: kubernetes_sd_configs:
- role: node - role: node
api_servers: api_server: 'https://localhost:1234'
- 'https://localhost:1234'
bearer_token: 1234 bearer_token: 1234
bearer_token_file: somefile bearer_token_file: somefile

View file

@ -3,8 +3,7 @@ scrape_configs:
kubernetes_sd_configs: kubernetes_sd_configs:
- role: pod - role: pod
api_servers: api_server: 'https://localhost:1234'
- 'https://localhost:1234'
bearer_token: 1234 bearer_token: 1234
basic_auth: basic_auth: