mirror of
https://github.com/grafana/grafana.git
synced 2025-02-10 15:45:43 -06:00
set basic auth for prometheus backend ds requests (#38496)
This commit is contained in:
parent
7751c0a706
commit
2e8a7c1161
@ -131,7 +131,6 @@ func (s *Service) QueryData(ctx context.Context, req *backend.QueryDataRequest)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
client, err := getClient(dsInfo, s)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
@ -181,8 +180,9 @@ func (s *Service) QueryData(ctx context.Context, req *backend.QueryDataRequest)
|
||||
|
||||
func getClient(dsInfo *DatasourceInfo, s *Service) (apiv1.API, error) {
|
||||
opts := &sdkhttpclient.Options{
|
||||
Timeouts: dsInfo.HTTPClientOpts.Timeouts,
|
||||
TLS: dsInfo.HTTPClientOpts.TLS,
|
||||
Timeouts: dsInfo.HTTPClientOpts.Timeouts,
|
||||
TLS: dsInfo.HTTPClientOpts.TLS,
|
||||
BasicAuth: dsInfo.HTTPClientOpts.BasicAuth,
|
||||
}
|
||||
|
||||
customMiddlewares := customQueryParametersMiddleware(plog)
|
||||
|
Loading…
Reference in New Issue
Block a user