We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a90710d commit 5ee3441Copy full SHA for 5ee3441
pkg/manifests/amcfg.go
@@ -193,10 +193,14 @@ func (f *Factory) ConvertToThanosAlertmanagerConfiguration(ta []AdditionalAlertm
193
194
proxyFunc := httpConfig.ProxyFunc()
195
196
- if len(cfg.StaticConfigs) > 0 && cfg.StaticConfigs[0] != "" {
+ for _, host := range cfg.StaticConfigs {
197
+ if host == "" {
198
+ continue
199
+ }
200
+
201
u := &url.URL{
202
Scheme: cfg.Scheme,
- Host: cfg.StaticConfigs[0],
203
+ Host: host,
204
}
205
206
proxyURL, err := proxyFunc(u)
@@ -206,6 +210,7 @@ func (f *Factory) ConvertToThanosAlertmanagerConfiguration(ta []AdditionalAlertm
210
207
211
if proxyURL != nil {
208
212
cfg.ProxyURL = proxyURL.String()
213
+ break
209
214
215
216
0 commit comments