Skip to content

Commit

Permalink
Merge pull request #63 from foomo/preview-autoscaling
Browse files Browse the repository at this point in the history
feat(sesamy-gtm): preview autoscaling
  • Loading branch information
franklinkim authored Feb 5, 2025
2 parents 38d9a6a + ef1d101 commit eb8f686
Show file tree
Hide file tree
Showing 41 changed files with 72 additions and 106 deletions.
2 changes: 1 addition & 1 deletion charts/contentserver/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,5 @@ annotations:
- name: Image Source
url: https://github.com/foomo/contentserver
version: 0.3.0
version: 0.3.1
appVersion: 1.11.2
4 changes: 2 additions & 2 deletions charts/contentserver/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# contentserver

![Version: 0.3.0](https://img.shields.io/badge/Version-0.3.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 1.11.2](https://img.shields.io/badge/AppVersion-1.11.2-informational?style=flat-square)
![Version: 0.3.1](https://img.shields.io/badge/Version-0.3.1-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 1.11.2](https://img.shields.io/badge/AppVersion-1.11.2-informational?style=flat-square)

Helm chart for the foomo Content Server.

Expand Down Expand Up @@ -150,7 +150,7 @@ Helm chart for the foomo Content Server.

| Key | Type | Default | Description |
|-----|------|---------|-------------|
| scheduling.affinity | object | `{"requiredDuringSchedulingIgnoredDuringExecution":{"nodeSelectorTerms":[{"matchExpressions":[{"key":"node-role.kubernetes.io/master","operator":"In","values":[""]}]}]}}` | Affinity for pod assignment |
| scheduling.affinity | object | `{"requiredDuringSchedulingIgnoredDuringExecution":{"nodeSelectorTerms":[{"matchExpressions":[{"key":"node-role.kubernetes.io/control-plane","operator":"In","values":[""]}]}]}}` | Affinity for pod assignment |
| scheduling.enabled | bool | `false` | Indicates wether scheduling is enabled or not |
| scheduling.nodeSelector | object | `{}` | Node labels for pod assignment |
| scheduling.priorityClass | string | `nil` | Priority class name |
Expand Down
2 changes: 1 addition & 1 deletion charts/contentserver/values.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -852,7 +852,7 @@
"additionalProperties": false,
"properties": {
"key": {
"default": "node-role.kubernetes.io/master",
"default": "node-role.kubernetes.io/control-plane",
"required": [],
"title": "key",
"type": "string"
Expand Down
2 changes: 1 addition & 1 deletion charts/contentserver/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -757,7 +757,7 @@ scheduling:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: node-role.kubernetes.io/master
- key: node-role.kubernetes.io/control-plane
operator: In
values: [""]
# @schema
Expand Down
2 changes: 1 addition & 1 deletion charts/sesamy-gtm/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@ annotations:
url: https://github.com/foomo/helm-charts/tree/main/charts/sesamy-gtm
- name: GTM Changelog
url: https://developers.google.com/tag-platform/tag-manager/server-side/release-notes
version: 0.3.0
version: 0.3.1
appVersion: 2.4.0
4 changes: 2 additions & 2 deletions charts/sesamy-gtm/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# sesamy-gtm

![Version: 0.3.0](https://img.shields.io/badge/Version-0.3.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 2.4.0](https://img.shields.io/badge/AppVersion-2.4.0-informational?style=flat-square)
![Version: 0.3.1](https://img.shields.io/badge/Version-0.3.1-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 2.4.0](https://img.shields.io/badge/AppVersion-2.4.0-informational?style=flat-square)

Helm chart for the Sesamy GTM tagging & preview service.

Expand Down Expand Up @@ -175,7 +175,7 @@ Helm chart for the Sesamy GTM tagging & preview service.

| Key | Type | Default | Description |
|-----|------|---------|-------------|
| scheduling.affinity | object | `{"requiredDuringSchedulingIgnoredDuringExecution":{"nodeSelectorTerms":[{"matchExpressions":[{"key":"node-role.kubernetes.io/master","operator":"In","values":[""]}]}]}}` | Affinity for pod assignment |
| scheduling.affinity | object | `{"requiredDuringSchedulingIgnoredDuringExecution":{"nodeSelectorTerms":[{"matchExpressions":[{"key":"node-role.kubernetes.io/control-plane","operator":"In","values":[""]}]}]}}` | Affinity for pod assignment |
| scheduling.enabled | bool | `false` | Indicates wether scheduling is enabled or not |
| scheduling.nodeSelector | object | `{}` | Node labels for pod assignment |
| scheduling.priorityClass | string | `nil` | Priority class name |
Expand Down
3 changes: 1 addition & 2 deletions charts/sesamy-gtm/templates/collect/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ include "sesamy.gtm.collect.fullname" . }}
labels:
{{- include "sesamy.gtm.collect.labels" . | nindent 4 }}
labels: {{- include "sesamy.gtm.collect.labels" . | nindent 4 }}
namespace: {{ include "sesamy.gtm.namespace" . }}
spec:
{{- if not .Values.autoscaling.enabled }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@ apiVersion: autoscaling/v2
kind: HorizontalPodAutoscaler
metadata:
name: {{ include "sesamy.gtm.collect.fullname" . }}
labels:
{{- include "sesamy.gtm.collect.labels" . | nindent 4 }}
labels: {{- include "sesamy.gtm.collect.labels" . | nindent 4 }}
namespace: {{ include "sesamy.gtm.namespace" . }}
spec:
scaleTargetRef:
Expand Down
10 changes: 3 additions & 7 deletions charts/sesamy-gtm/templates/collect/poddisruptionbudget.yaml
Original file line number Diff line number Diff line change
@@ -1,21 +1,17 @@
{{- if .Values.collect.enabled }}
{{- if gt (int .Values.collect.replicaCount) 1 }}
{{- if and .Values.collect.enabled .Values.autoscaling.enabled }}
apiVersion: policy/v1
kind: PodDisruptionBudget
metadata:
name: {{ include "sesamy.gtm.collect.fullname" . }}
labels:
{{- include "sesamy.gtm.collect.labels" . | nindent 4 }}
labels: {{- include "sesamy.gtm.collect.labels" . | nindent 4 }}
namespace: {{ include "sesamy.gtm.namespace" . }}
spec:
selector:
matchLabels:
{{- include "sesamy.gtm.collect.selectorLabels" . | nindent 6 }}
matchLabels: {{- include "sesamy.gtm.collect.selectorLabels" . | nindent 6 }}
{{- with .Values.autoscaling.minAvailable }}
minAvailable: {{ . }}
{{- end }}
{{- with .Values.autoscaling.maxUnavailable }}
maxUnavailable: {{ . }}
{{- end }}
{{- end }}
{{- end }}
6 changes: 2 additions & 4 deletions charts/sesamy-gtm/templates/collect/service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,9 @@ apiVersion: v1
kind: Service
metadata:
name: {{ include "sesamy.gtm.collect.fullname" . }}
labels:
{{- include "sesamy.gtm.collect.labels" . | nindent 4 }}
labels: {{- include "sesamy.gtm.collect.labels" . | nindent 4 }}
{{- with .Values.collect.service.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
annotations: {{- toYaml . | nindent 4 }}
{{- end }}
namespace: {{ include "sesamy.gtm.namespace" . }}
spec:
Expand Down
21 changes: 7 additions & 14 deletions charts/sesamy-gtm/templates/preview/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@ apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ include "sesamy.gtm.preview.fullname" . }}
labels:
{{- include "sesamy.gtm.preview.labels" . | nindent 4 }}
labels: {{- include "sesamy.gtm.preview.labels" . | nindent 4 }}
namespace: {{ include "sesamy.gtm.namespace" . }}
spec:
{{- if not .Values.autoscaling.enabled }}
Expand All @@ -13,8 +12,7 @@ spec:
strategy:
type: {{ .Values.updateStrategy }}
selector:
matchLabels:
{{- include "sesamy.gtm.preview.selectorLabels" . | nindent 6 }}
matchLabels: {{- include "sesamy.gtm.preview.selectorLabels" . | nindent 6 }}
template:
metadata:
labels:
Expand All @@ -30,16 +28,13 @@ spec:
spec:
serviceAccountName: {{ include "sesamy.gtm.serviceAccountName" . }}
{{- with .Values.preview.imagePullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 8 }}
imagePullSecrets: {{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.preview.hostAliases }}
hostAliases:
{{- toYaml . | nindent 8 }}
hostAliases: {{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.preview.podSecurityContext }}
securityContext:
{{- toYaml . | nindent 8 }}
securityContext: {{- toYaml . | nindent 8 }}
{{- end }}
containers:
- name: gtm-preview-proxy
Expand All @@ -57,8 +52,7 @@ spec:
tcpSocket:
port: 443
{{- with .Values.proxy.resources }}
resources:
{{- toYaml . | nindent 12 }}
resources: {{- toYaml . | nindent 12 }}
{{- end }}
volumeMounts:
- name: gtm-preview-proxy-config
Expand All @@ -73,8 +67,7 @@ spec:
imagePullPolicy: {{ .pullPolicy }}
{{- end }}
{{- with .Values.preview.securityContext }}
securityContext:
{{- toYaml . | nindent 12 }}
securityContext: {{- toYaml . | nindent 12 }}
{{- end }}
ports:
- name: http
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ apiVersion: autoscaling/v2
kind: HorizontalPodAutoscaler
metadata:
name: {{ include "sesamy.gtm.preview.fullname" . }}
labels:
{{- include "sesamy.gtm.preview.labels" . | nindent 4 }}
labels: {{- include "sesamy.gtm.preview.labels" . | nindent 4 }}
namespace: {{ include "sesamy.gtm.namespace" . }}
spec:
scaleTargetRef:
Expand Down
8 changes: 3 additions & 5 deletions charts/sesamy-gtm/templates/preview/poddisruptionbudget.yaml
Original file line number Diff line number Diff line change
@@ -1,15 +1,13 @@
{{- if gt (int .Values.preview.replicaCount) 1 }}
{{- if .Values.autoscaling.enabled }}
apiVersion: policy/v1
kind: PodDisruptionBudget
metadata:
name: {{ include "sesamy.gtm.preview.fullname" . }}
labels:
{{- include "sesamy.gtm.preview.labels" . | nindent 4 }}
labels: {{- include "sesamy.gtm.preview.labels" . | nindent 4 }}
namespace: {{ include "sesamy.gtm.namespace" . }}
spec:
selector:
matchLabels:
{{- include "sesamy.gtm.preview.selectorLabels" . | nindent 6 }}
matchLabels: {{- include "sesamy.gtm.preview.selectorLabels" . | nindent 6 }}
{{- with .Values.autoscaling.minAvailable }}
minAvailable: {{ . }}
{{- end }}
Expand Down
9 changes: 3 additions & 6 deletions charts/sesamy-gtm/templates/preview/service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,9 @@ apiVersion: v1
kind: Service
metadata:
name: {{ include "sesamy.gtm.preview.fullname" . }}
labels:
{{- include "sesamy.gtm.preview.labels" . | nindent 4 }}
labels: {{- include "sesamy.gtm.preview.labels" . | nindent 4 }}
{{- with .Values.preview.service.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
annotations: {{- toYaml . | nindent 4 }}
{{- end }}
namespace: {{ include "sesamy.gtm.namespace" . }}
spec:
Expand All @@ -18,5 +16,4 @@ spec:
- name: http
port: {{ .Values.preview.service.port }}
targetPort: http
selector:
{{- include "sesamy.gtm.preview.selectorLabels" . | nindent 4 }}
selector: {{- include "sesamy.gtm.preview.selectorLabels" . | nindent 4 }}
16 changes: 5 additions & 11 deletions charts/sesamy-gtm/templates/tagging/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@ apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ include "sesamy.gtm.tagging.fullname" . }}
labels:
{{- include "sesamy.gtm.tagging.labels" . | nindent 4 }}
labels: {{- include "sesamy.gtm.tagging.labels" . | nindent 4 }}
namespace: {{ include "sesamy.gtm.namespace" . }}
spec:
{{- if not .Values.autoscaling.enabled }}
Expand All @@ -18,8 +17,7 @@ spec:
template:
metadata:
{{- with .Values.tagging.podAnnotations }}
annotations:
{{- toYaml . | nindent 8 }}
annotations: {{- toYaml . | nindent 8 }}
{{- end }}
labels:
{{- include "sesamy.gtm.tagging.labels" . | nindent 8 }}
Expand All @@ -29,16 +27,13 @@ spec:
spec:
serviceAccountName: {{ include "sesamy.gtm.serviceAccountName" . }}
{{- with .Values.tagging.imagePullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 8 }}
imagePullSecrets: {{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.tagging.hostAliases }}
hostAliases:
{{- toYaml . | nindent 8 }}
hostAliases: {{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.tagging.podSecurityContext }}
securityContext:
{{- toYaml . | nindent 8 }}
securityContext: {{- toYaml . | nindent 8 }}
{{- end }}
containers:
- name: gtm-tagging
Expand Down Expand Up @@ -125,7 +120,6 @@ spec:
- {{ toYaml (mergeOverwrite $labelSelector .) | nindent 10 }}
{{- end }}
{{- end }}

{{- end }}
{{- if or .Values.gtm.googleApplicationCredentials .Values.tagging.extraVolumes }}
volumes:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ apiVersion: autoscaling/v2
kind: HorizontalPodAutoscaler
metadata:
name: {{ include "sesamy.gtm.tagging.fullname" . }}
labels:
{{- include "sesamy.gtm.tagging.labels" . | nindent 4 }}
labels: {{- include "sesamy.gtm.tagging.labels" . | nindent 4 }}
namespace: {{ include "sesamy.gtm.namespace" . }}
spec:
scaleTargetRef:
Expand Down
6 changes: 2 additions & 4 deletions charts/sesamy-gtm/templates/tagging/poddisruptionbudget.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,10 @@ apiVersion: policy/v1
kind: PodDisruptionBudget
metadata:
name: {{ include "sesamy.gtm.tagging.fullname" . }}
labels:
{{- include "sesamy.gtm.tagging.labels" . | nindent 4 }}
labels: {{- include "sesamy.gtm.tagging.labels" . | nindent 4 }}
spec:
selector:
matchLabels:
{{- include "sesamy.gtm.tagging.selectorLabels" . | nindent 6 }}
matchLabels: {{- include "sesamy.gtm.tagging.selectorLabels" . | nindent 6 }}
{{- with .Values.autoscaling.minAvailable }}
minAvailable: {{ . }}
{{- end }}
Expand Down
3 changes: 1 addition & 2 deletions charts/sesamy-gtm/templates/tagging/secret.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ apiVersion: v1
kind: Secret
metadata:
name: {{ include "sesamy.gtm.tagging.fullname" . }}
labels:
{{- include "sesamy.gtm.tagging.labels" . | nindent 4 }}
labels: {{- include "sesamy.gtm.tagging.labels" . | nindent 4 }}
namespace: {{ include "sesamy.gtm.namespace" . }}
type: Opaque
data:
Expand Down
9 changes: 3 additions & 6 deletions charts/sesamy-gtm/templates/tagging/service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,9 @@ apiVersion: v1
kind: Service
metadata:
name: {{ include "sesamy.gtm.tagging.fullname" . }}
labels:
{{- include "sesamy.gtm.tagging.labels" . | nindent 4 }}
labels: {{- include "sesamy.gtm.tagging.labels" . | nindent 4 }}
{{- with .Values.tagging.service.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
annotations: {{- toYaml . | nindent 4 }}
{{- end }}
namespace: {{ include "sesamy.gtm.namespace" . }}
spec:
Expand All @@ -25,5 +23,4 @@ spec:
{{- with .Values.tagging.service.appProtocol }}
appProtocol: {{ . }}
{{- end }}
selector:
{{- include "sesamy.gtm.tagging.selectorLabels" . | nindent 4 }}
selector: {{- include "sesamy.gtm.tagging.selectorLabels" . | nindent 4 }}
2 changes: 1 addition & 1 deletion charts/sesamy-gtm/values.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -1422,7 +1422,7 @@
"additionalProperties": false,
"properties": {
"key": {
"default": "node-role.kubernetes.io/master",
"default": "node-role.kubernetes.io/control-plane",
"required": [],
"title": "key",
"type": "string"
Expand Down
2 changes: 1 addition & 1 deletion charts/sesamy-gtm/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1118,7 +1118,7 @@ scheduling:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: node-role.kubernetes.io/master
- key: node-role.kubernetes.io/control-plane
operator: In
values: [""]
# @schema
Expand Down
2 changes: 1 addition & 1 deletion charts/sesamy-umami/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@ annotations:
url: https://github.com/foomo/helm-charts/tree/main/charts/sesamy-umami
- name: Umami Source
url: https://github.com/umami-software/umami
version: 0.2.0
version: 0.2.1
appVersion: 2.15.1
4 changes: 2 additions & 2 deletions charts/sesamy-umami/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# sesamy-umami

![Version: 0.2.0](https://img.shields.io/badge/Version-0.2.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 2.15.1](https://img.shields.io/badge/AppVersion-2.15.1-informational?style=flat-square)
![Version: 0.2.1](https://img.shields.io/badge/Version-0.2.1-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 2.15.1](https://img.shields.io/badge/AppVersion-2.15.1-informational?style=flat-square)

Helm chart for the Sesamy Umami integration.

Expand Down Expand Up @@ -70,7 +70,7 @@ Helm chart for the Sesamy Umami integration.

| Key | Type | Default | Description |
|-----|------|---------|-------------|
| scheduling.affinity | object | `{"requiredDuringSchedulingIgnoredDuringExecution":{"nodeSelectorTerms":[{"matchExpressions":[{"key":"node-role.kubernetes.io/master","operator":"In","values":[""]}]}]}}` | Affinity for pod assignment |
| scheduling.affinity | object | `{"requiredDuringSchedulingIgnoredDuringExecution":{"nodeSelectorTerms":[{"matchExpressions":[{"key":"node-role.kubernetes.io/control-plane","operator":"In","values":[""]}]}]}}` | Affinity for pod assignment |
| scheduling.enabled | bool | `false` | Indicates wether scheduling is enabled or not |
| scheduling.nodeSelector | object | `{}` | Node labels for pod assignment |
| scheduling.priorityClass | string | `nil` | Priority class name |
Expand Down
2 changes: 1 addition & 1 deletion charts/sesamy-umami/values.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -390,7 +390,7 @@
"additionalProperties": false,
"properties": {
"key": {
"default": "node-role.kubernetes.io/master",
"default": "node-role.kubernetes.io/control-plane",
"required": [],
"title": "key",
"type": "string"
Expand Down
2 changes: 1 addition & 1 deletion charts/sesamy-umami/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -804,7 +804,7 @@ scheduling:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: node-role.kubernetes.io/master
- key: node-role.kubernetes.io/control-plane
operator: In
values: [""]
# @schema
Expand Down
Loading

0 comments on commit eb8f686

Please sign in to comment.