mirror of
https://github.com/pezkuwichain/pezkuwi-telemetry.git
synced 2026-06-13 19:41:02 +00:00
adding servicemonitor for the core service
changing the ci to trigger automatically
This commit is contained in:
+4
-4
@@ -18,7 +18,7 @@ stages:
|
|||||||
image: quay.io/buildah/stable
|
image: quay.io/buildah/stable
|
||||||
rules:
|
rules:
|
||||||
- if: '$CI_COMMIT_BRANCH == "master"'
|
- if: '$CI_COMMIT_BRANCH == "master"'
|
||||||
# when: manual # uncomment this line if we want to make this step a manual process
|
when: always
|
||||||
tags:
|
tags:
|
||||||
- kubernetes-parity-build
|
- kubernetes-parity-build
|
||||||
|
|
||||||
@@ -33,7 +33,7 @@ stages:
|
|||||||
- |-
|
- |-
|
||||||
sed -i "s/appVersion:.*/appVersion: $KUBERNETES_VERSION_TAG/" ./helm/Chart.yaml
|
sed -i "s/appVersion:.*/appVersion: $KUBERNETES_VERSION_TAG/" ./helm/Chart.yaml
|
||||||
# validate the chart
|
# validate the chart
|
||||||
- helm --debug template
|
- helm template
|
||||||
--create-namespace
|
--create-namespace
|
||||||
--namespace $KUBE_NAMESPACE
|
--namespace $KUBE_NAMESPACE
|
||||||
--set image.backend.repository="${CONTAINER_REGISTRY}/${BACKEND_CONTAINER_REPO}"
|
--set image.backend.repository="${CONTAINER_REGISTRY}/${BACKEND_CONTAINER_REPO}"
|
||||||
@@ -42,7 +42,7 @@ stages:
|
|||||||
--set image.frontend.tag="${CI_COMMIT_SHORT_SHA}"
|
--set image.frontend.tag="${CI_COMMIT_SHORT_SHA}"
|
||||||
$KUBE_NAMESPACE ./helm/
|
$KUBE_NAMESPACE ./helm/
|
||||||
# install the chart into the relevant cluster
|
# install the chart into the relevant cluster
|
||||||
- helm --debug upgrade
|
- helm upgrade
|
||||||
--install
|
--install
|
||||||
--atomic
|
--atomic
|
||||||
--timeout 120s
|
--timeout 120s
|
||||||
@@ -55,7 +55,7 @@ stages:
|
|||||||
$KUBE_NAMESPACE ./helm/
|
$KUBE_NAMESPACE ./helm/
|
||||||
rules:
|
rules:
|
||||||
- if: '$CI_COMMIT_BRANCH == "master"'
|
- if: '$CI_COMMIT_BRANCH == "master"'
|
||||||
# when: manual # uncomment this line if we want to make this step a manual process
|
when: on-success
|
||||||
tags:
|
tags:
|
||||||
- kubernetes-parity-build
|
- kubernetes-parity-build
|
||||||
|
|
||||||
|
|||||||
Binary file not shown.
@@ -12,6 +12,7 @@ spec:
|
|||||||
selector:
|
selector:
|
||||||
matchLabels:
|
matchLabels:
|
||||||
{{- include "substrate-telemetry.selectorLabels" . | nindent 6 }}
|
{{- include "substrate-telemetry.selectorLabels" . | nindent 6 }}
|
||||||
|
telemetry-component: core
|
||||||
template:
|
template:
|
||||||
metadata:
|
metadata:
|
||||||
{{- with .Values.podAnnotations }}
|
{{- with .Values.podAnnotations }}
|
||||||
|
|||||||
@@ -0,0 +1,32 @@
|
|||||||
|
{{- if .Values.serviceMonitor.core.enabled }}
|
||||||
|
apiVersion: monitoring.coreos.com/v1
|
||||||
|
kind: ServiceMonitor
|
||||||
|
metadata:
|
||||||
|
name: telemetry-core
|
||||||
|
labels:
|
||||||
|
{{- include "substrate-telemetry.labels" . | nindent 4 }}
|
||||||
|
telemetry-component: core
|
||||||
|
{{- if .Values.serviceMonitor.core.additionalLabels }}
|
||||||
|
{{ toYaml .Values.serviceMonitor.core.additionalLabels | indent 4 }}
|
||||||
|
{{- end }}
|
||||||
|
{{- if .Values.serviceMonitor.core.annotations }}
|
||||||
|
annotations:
|
||||||
|
{{ toYaml .Values.serviceMonitor.core.annotations | indent 4 }}
|
||||||
|
{{- end }}
|
||||||
|
spec:
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
{{- include "substrate-telemetry.selectorLabels" . | nindent 6 }}
|
||||||
|
telemetry-component: core
|
||||||
|
namespaceSelector:
|
||||||
|
matchNames:
|
||||||
|
- {{ .Release.Namespace | quote }}
|
||||||
|
endpoints:
|
||||||
|
- port: http
|
||||||
|
{{- if .Values.serviceMonitor.core.interval }}
|
||||||
|
interval: {{ .Values.serviceMonitor.core.interval }}
|
||||||
|
{{- end }}
|
||||||
|
{{- if .Values.serviceMonitor.core.scrapeTimeout }}
|
||||||
|
scrapeTimeout: {{ .Values.serviceMonitor.core.scrapeTimeout }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
@@ -12,6 +12,7 @@ spec:
|
|||||||
selector:
|
selector:
|
||||||
matchLabels:
|
matchLabels:
|
||||||
{{- include "substrate-telemetry.selectorLabels" . | nindent 6 }}
|
{{- include "substrate-telemetry.selectorLabels" . | nindent 6 }}
|
||||||
|
telemetry-component: frontend
|
||||||
template:
|
template:
|
||||||
metadata:
|
metadata:
|
||||||
{{- with .Values.podAnnotations }}
|
{{- with .Values.podAnnotations }}
|
||||||
|
|||||||
@@ -12,6 +12,7 @@ spec:
|
|||||||
selector:
|
selector:
|
||||||
matchLabels:
|
matchLabels:
|
||||||
{{- include "substrate-telemetry.selectorLabels" . | nindent 6 }}
|
{{- include "substrate-telemetry.selectorLabels" . | nindent 6 }}
|
||||||
|
telemetry-component: shard
|
||||||
template:
|
template:
|
||||||
metadata:
|
metadata:
|
||||||
{{- with .Values.podAnnotations }}
|
{{- with .Values.podAnnotations }}
|
||||||
|
|||||||
+19
-1
@@ -28,7 +28,25 @@ envVars:
|
|||||||
core: {}
|
core: {}
|
||||||
frontend: {}
|
frontend: {}
|
||||||
|
|
||||||
|
serviceMonitor:
|
||||||
|
shard:
|
||||||
|
enabled: false
|
||||||
|
interval: ""
|
||||||
|
additionalLabels: {}
|
||||||
|
annotations: {}
|
||||||
|
# scrapeTimeout: 10s
|
||||||
|
core:
|
||||||
|
enabled: true
|
||||||
|
interval: ""
|
||||||
|
additionalLabels: {}
|
||||||
|
annotations: {}
|
||||||
|
# scrapeTimeout: 10s
|
||||||
|
frontend:
|
||||||
|
enabled: false
|
||||||
|
interval: ""
|
||||||
|
additionalLabels: {}
|
||||||
|
annotations: {}
|
||||||
|
# scrapeTimeout: 10s
|
||||||
|
|
||||||
serviceAccount:
|
serviceAccount:
|
||||||
# Specifies whether a service account should be created
|
# Specifies whether a service account should be created
|
||||||
|
|||||||
Reference in New Issue
Block a user