-
Notifications
You must be signed in to change notification settings - Fork 3.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Add a minimal prometheus server manifest (#4687)
Signed-off-by: Simon Behar <simbeh7@gmail.com>
- Loading branch information
Showing
7 changed files
with
88 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
apiVersion: kustomize.config.k8s.io/v1beta1 | ||
kind: Kustomization | ||
|
||
resources: | ||
- prometheus-deployment.yaml | ||
- prometheus-config-cluster.yaml |
12 changes: 12 additions & 0 deletions
12
manifests/quick-start/base/prometheus/prometheus-config-cluster.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
apiVersion: v1 | ||
kind: ConfigMap | ||
metadata: | ||
name: prometheus-config | ||
data: | ||
prometheus.yaml: | | ||
global: | ||
scrape_interval: 15s | ||
scrape_configs: | ||
- job_name: 'argo' | ||
static_configs: | ||
- targets: ['workflow-controller-metrics:9090'] |
37 changes: 37 additions & 0 deletions
37
manifests/quick-start/base/prometheus/prometheus-deployment.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
# This manifests creates a minimal Prometheus server to scrape and display the metrics emitted by the workflow | ||
# controller. To open this server, create an external IP for the prometheus service or use kubectl port-forward, | ||
# then open: | ||
# | ||
# localhost:9091/graph | ||
# | ||
# Note: this assumes the workflow-controller is emitting metrics in the default port (9090). This will need to | ||
# be modified if the default is overriden. | ||
apiVersion: apps/v1 | ||
kind: Deployment | ||
metadata: | ||
name: prometheus | ||
spec: | ||
replicas: 1 | ||
selector: | ||
matchLabels: | ||
app: prometheus | ||
template: | ||
metadata: | ||
labels: | ||
app: prometheus | ||
name: prometheus | ||
spec: | ||
containers: | ||
- name: prometheus | ||
image: prom/prometheus | ||
args: | ||
- --config.file=/config/prometheus.yaml | ||
volumeMounts: | ||
- name: config | ||
mountPath: /config | ||
volumes: | ||
- name: config | ||
configMap: | ||
name: prometheus-config | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
apiVersion: kustomize.config.k8s.io/v1beta1 | ||
kind: Kustomization | ||
|
||
resources: | ||
- ../../../../manifests/quick-start/minimal | ||
- ../../../../manifests/quick-start/base/prometheus | ||
|
||
patchesStrategicMerge: | ||
- ../mixins/argo-server-deployment.yaml | ||
- ../mixins/workflow-controller-configmap.yaml | ||
- ../mixins/workflow-controller-deployment.yaml | ||
- ../mixins/cluster-workflow-template-rbac.yaml | ||
|
||
commonLabels: | ||
"app.kubernetes.io/part-of": "argo" |