change servicemesh prometheus to kubesphere monitoring prometheus
This commit is contained in:
@@ -14,6 +14,9 @@ type ServerRunOptions struct {
|
|||||||
// jaeger query service url
|
// jaeger query service url
|
||||||
JaegerQueryServiceUrl string
|
JaegerQueryServiceUrl string
|
||||||
|
|
||||||
|
// prometheus service url for servicemesh metrics
|
||||||
|
ServicemeshPrometheusServiceUrl string
|
||||||
|
|
||||||
// openpitrix api gateway service url
|
// openpitrix api gateway service url
|
||||||
OpenPitrixServer string
|
OpenPitrixServer string
|
||||||
|
|
||||||
@@ -38,5 +41,5 @@ func (s *ServerRunOptions) AddFlags(fs *pflag.FlagSet) {
|
|||||||
|
|
||||||
fs.StringVar(&s.IstioPilotServiceURL, "istio-pilot-service-url", "http://istio-pilot.istio-system.svc:8080/version", "istio pilot discovery service url")
|
fs.StringVar(&s.IstioPilotServiceURL, "istio-pilot-service-url", "http://istio-pilot.istio-system.svc:8080/version", "istio pilot discovery service url")
|
||||||
fs.StringVar(&s.JaegerQueryServiceUrl, "jaeger-query-service-url", "http://jaeger-query.istio-system.svc:16686/jaeger", "jaeger query service url")
|
fs.StringVar(&s.JaegerQueryServiceUrl, "jaeger-query-service-url", "http://jaeger-query.istio-system.svc:16686/jaeger", "jaeger query service url")
|
||||||
|
fs.StringVar(&s.ServicemeshPrometheusServiceUrl, "servicemesh-prometheus-service-url", "http://prometheus-k8s-system.kubesphere-monitoring-system.svc:9090", "prometheus service for servicemesh")
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -121,8 +121,7 @@ func initializeServicemeshConfig(s *options.ServerRunOptions) {
|
|||||||
config.InCluster = true
|
config.InCluster = true
|
||||||
|
|
||||||
// Set default prometheus service url
|
// Set default prometheus service url
|
||||||
// TODO: use kubesphere builtin p8s instead of istio p8s
|
config.ExternalServices.PrometheusServiceURL = s.ServicemeshPrometheusServiceUrl
|
||||||
config.ExternalServices.PrometheusServiceURL = "http://prometheus.istio-system.svc.cluster.local:9090"
|
|
||||||
config.ExternalServices.PrometheusCustomMetricsURL = config.ExternalServices.PrometheusServiceURL
|
config.ExternalServices.PrometheusCustomMetricsURL = config.ExternalServices.PrometheusServiceURL
|
||||||
|
|
||||||
// Set istio pilot discovery service url
|
// Set istio pilot discovery service url
|
||||||
|
|||||||
Reference in New Issue
Block a user