Skip to content
Open
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions charts/sophora-ugc-proxy/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@ description: A Helm chart for Kubernetes to install Sophora UGC Proxy connected

type: application

version: 1.5.3
version: 1.6.0
annotations:
artifacthub.io/changes: |
- kind: fixed
description: "Fixed linter errors"
- kind: added
description: "ServiceMonitor object for UGC proxy"

# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application. Versions are not expected to
Expand Down
3 changes: 2 additions & 1 deletion charts/sophora-ugc-proxy/templates/service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ spec:
{{- include "sophora-ugc-proxy.selectorLabels" . | nindent 4 }}
type: {{ .Values.service.type }}
ports:
- protocol: TCP
- name: http
protocol: TCP
targetPort: proxy
port: {{ .Values.service.port }}
15 changes: 15 additions & 0 deletions charts/sophora-ugc-proxy/templates/servicemonitor.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{{- if .Values.serviceMonitor.enabled -}}
{{- $fullName := include "sophora-ugc-proxy.fullname" . -}}
apiVersion: monitoring.coreos.com/v1
kind: ServiceMonitor
metadata:
name: {{ $fullName }}
labels: {{- include "sophora-ugc-proxy.labels" . | nindent 8 }}
spec:
selector:
matchLabels: {{- include "sophora-ugc-proxy.selectorLabels" . | nindent 12 }}
endpoints:
- interval: {{ .Values.serviceMonitor.interval }}
port: http
path: {{ .Values.serviceMonitor.path }}
{{- end }}
9 changes: 9 additions & 0 deletions charts/sophora-ugc-proxy/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -218,3 +218,12 @@ gcp:

# extraDeploy is a list of full Kubernetes manifests that will be rendered additionally by this chart
extraDeploy: []


# serviceMonitor.enabled Whether the serviceMonitor resource should be deployed
# serviceMonitor.interval Prometheus scrape interval
# serviceMonitor.path HTTP path prometheus should use to scrape the application's metrics
serviceMonitor:
enabled: false
interval: 10s
path: "/actuator/prometheus"
6 changes: 3 additions & 3 deletions charts/sophora-ugc/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@ type: application
# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
version: 2.10.4
version: 2.11.0
annotations:
artifacthub.io/changes: |
- kind: fixed
description: "fix linting issue on enabled GCPHealthChecks and GCPBackendPolicies"
- kind: added
description: "ServiceMonitor objects for UGC and UGC multimedia"
artifacthub.io/links: |
- name: Documentation for Sophora UGC
url: https://subshell.com/docs/ugc/
Expand Down
2 changes: 1 addition & 1 deletion charts/sophora-ugc/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ spec:
- containerPort: {{ default 8080 (.Values.ugc.config.server).port }}
name: webapp
- containerPort: 1694
name: jolokia
name: management
Comment thread
DanielRaapDev marked this conversation as resolved.
volumeMounts:
- name: logback-xml
mountPath: /config/logback
Expand Down
15 changes: 15 additions & 0 deletions charts/sophora-ugc/templates/servicemonitor.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{{- if .Values.ugc.serviceMonitor.enabled -}}
{{- $fullName := include "sophora-ugc.fullname" . -}}
apiVersion: monitoring.coreos.com/v1
kind: ServiceMonitor
metadata:
name: {{ $fullName }}
labels: {{- include "sophora-ugc.labels" . | nindent 8 }}
spec:
selector:
matchLabels: {{- include "sophora-ugc.selectorLabels" . | nindent 12 }}
endpoints:
- interval: {{ .Values.ugc.serviceMonitor.interval }}
port: http
path: {{ .Values.ugc.serviceMonitor.path }}
Comment thread
DanielRaapDev marked this conversation as resolved.
{{- end }}
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@ spec:
type: {{ .Values.service.webapp.type }}
loadBalancerIP: {{ .Values.service.webapp.loadBalancerIP }}
ports:
- port: 80
- name: http
port: 80
targetPort: {{ default 8080 (.Values.ugcMultimedia.config.server).port }}
protocol: TCP
selector:
Expand Down
15 changes: 15 additions & 0 deletions charts/sophora-ugc/templates/ugc-multimedia/servicemonitor.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{{- if .Values.ugcMultimedia.serviceMonitor.enabled -}}
{{- $fullName := include "sophora-ugc-multimedia.fullname" . -}}
Comment thread
Copilot marked this conversation as resolved.
Outdated
apiVersion: monitoring.coreos.com/v1
kind: ServiceMonitor
metadata:
name: {{ $fullName }}
labels: {{- include "sophora-ugc-multimedia.labels" . | nindent 8 }}
spec:
selector:
matchLabels: {{- include "sophora-ugc-multimedia.selectorLabels" . | nindent 12 }}
endpoints:
- interval: {{ .Values.ugcMultimedia.serviceMonitor.interval }}
port: http
path: {{ .Values.ugcMultimedia.serviceMonitor.path }}
{{- end }}
3 changes: 2 additions & 1 deletion charts/sophora-ugc/templates/webapp-service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ spec:
loadBalancerIP: {{ .Values.service.webapp.loadBalancerIP }}
{{- end }}
ports:
- port: 80
- name: http
port: 80
targetPort: {{ default 8080 (.Values.ugc.config.server).port }}
protocol: TCP
selector:
Expand Down
18 changes: 17 additions & 1 deletion charts/sophora-ugc/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,13 @@ ugc:
# The name of the service account to use.
# If not set and create is true, a name is generated using the fullname template
name: ""
# serviceMonitor.enabled Whether the serviceMonitor resource should be deployed
# serviceMonitor.interval Prometheus scrape interval
# serviceMonitor.path HTTP path prometheus should use to scrape the application's metrics
serviceMonitor:
enabled: false
interval: 10s
path: "/actuator/prometheus"

ugcMultimedia:
enabled: false
Expand Down Expand Up @@ -209,6 +216,15 @@ ugcMultimedia:
fs:
baseDir: /binaries/

# serviceMonitor.enabled Whether the serviceMonitor resource should be deployed
# serviceMonitor.interval Prometheus scrape interval
# serviceMonitor.path HTTP path prometheus should use to scrape the application's metrics
serviceMonitor:
enabled: false
interval: 10s
path: "/actuator/prometheus"


# Additional environment variables can be defined here
env:

Expand Down Expand Up @@ -269,4 +285,4 @@ gcp:
# iap:
# enabled: false
# oauth2ClientSecretName: ""
# clientID: ""
# clientID: ""
Loading