Skip to content

Commit

Permalink
Revise prometheus export api (#27)
Browse files Browse the repository at this point in the history
Going forward AppsCode operators will only add Prometheus exporter sidecar and create a stats service. It will not apply Promethus annotations on stats service or create ServiceMonitor.
xref: #25

Signed-off-by: Tamal Saha <[email protected]>
  • Loading branch information
tamalsaha authored Dec 23, 2019
1 parent 25b3711 commit 784042d
Show file tree
Hide file tree
Showing 7 changed files with 673 additions and 51 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ gen-crd-protos:
--packages=-k8s.io/api/core/v1,kmodules.xyz/monitoring-agent-api/api/v1

.PHONY: gen
gen: clientset openapi gen-crd-protos
gen: clientset gen-crd-protos openapi

fmt: $(BUILD_DIRS)
@docker run \
Expand Down
2 changes: 1 addition & 1 deletion agents/agents.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ import (

func New(at api.AgentType, k8sClient kubernetes.Interface, extClient ecs.ApiextensionsV1beta1Interface, promClient prom.MonitoringV1Interface) api.Agent {
switch at {
case api.AgentPrometheusOperator, api.AgentCoreOSPrometheus, api.DeprecatedAgentCoreOSPrometheus:
case api.AgentPrometheus, api.AgentCoreOSPrometheus, api.DeprecatedAgentCoreOSPrometheus:
return coreosprometheusoperator.New(at, k8sClient, extClient, promClient)
case api.AgentPrometheusBuiltin:
return prometheusbuiltin.New(k8sClient)
Expand Down
Loading

0 comments on commit 784042d

Please sign in to comment.