Skip to content
Open
Show file tree
Hide file tree
Changes from all 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
4 changes: 2 additions & 2 deletions charts/hawkbit/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
# SPDX-License-Identifier: EPL-2.0
---
apiVersion: v2
version: 1.7.0
appVersion: "0.5.0-mysql"
version: 2.0.0
appVersion: "0.8.0"
description: |
Eclipse hawkBit™ is a domain independent back-end framework for rolling out software updates
to constrained edge devices as well as more powerful controllers and gateways connected to
Expand Down
11 changes: 11 additions & 0 deletions charts/hawkbit/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -54,3 +54,14 @@ Return the appropriate apiVersion for ingress.
{{- print "networking.k8s.io/v1beta1" -}}
{{- end -}}
{{- end -}}

{{- define "hawkbit.ingressDefaultPaths" -}}
- path: "/rest"
service: {{ include "hawkbit.fullname" . }}
- path: "/swagger-ui"
service: {{ include "hawkbit.fullname" . }}
- path: "/v3"
service: {{ include "hawkbit.fullname" . }}
- path: "/"
service: {{ include "hawkbit.fullname" . }}-simple-ui
{{- end -}}
82 changes: 82 additions & 0 deletions charts/hawkbit/templates/deployment-simple-ui.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
{{- $hawkbit_service_name := include "hawkbit.fullname" . -}}
apiVersion: apps/v1
kind: Deployment
metadata:
name: "{{ include "hawkbit.fullname" . }}-simple-ui"
labels:
app.kubernetes.io/name: "{{ include "hawkbit.name" . }}-simple-ui"
spec:
replicas: {{ .Values.serviceSimpleUI.replicaCount }}
strategy:
{{- with .Values.serviceSimpleUI.updateStrategy }}
{{- toYaml . | nindent 4 }}
{{- end }}
selector:
matchLabels:
app.kubernetes.io/name: "{{ include "hawkbit.name" . }}-simple-ui"
app.kubernetes.io/instance: {{ .Release.Name }}
template:
metadata:
labels:
app.kubernetes.io/name: "{{ include "hawkbit.name" . }}-simple-ui"
app.kubernetes.io/instance: {{ .Release.Name }}
annotations:
checksum/config: {{ include (print .Template.BasePath "/secrets.yaml") . | sha256sum }}
{{- with .Values.podTemplate.annotations }}
{{- toYaml . | nindent 8 }}
{{- end }}
spec:
{{- with .Values.simpleUIImage.pullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 8 }}
{{- end }}
containers:
- name: "{{ .Chart.Name }}-simple-ui"
image: "{{ .Values.simpleUIImage.repository }}:{{ .Values.simpleUIImage.tag }}"
imagePullPolicy: {{ .Values.simpleUIImage.pullPolicy }}
env:
- name: HAWKBIT_SERVER_MGMTURL
value: {{ .Values.envSimpleUI.hawkbitServerMgmtUrl | default (printf "http://%s:%v" $hawkbit_service_name $.Values.service.port ) }}
- name: "SPRING_APPLICATION_JSON"
valueFrom:
secretKeyRef:
name: {{ include "hawkbit.fullname" . }}
key: SIMPLE_UI_SPRING_APPLICATION_JSON
ports:
- name: http
containerPort: 8088
protocol: TCP
livenessProbe:
httpGet:
path: /login
port: http
initialDelaySeconds: {{ .Values.livenessProbe.initialDelaySeconds }}
timeoutSeconds: {{ .Values.livenessProbe.timeoutSeconds }}
readinessProbe:
httpGet:
path: /login
port: http
initialDelaySeconds: {{ .Values.readinessProbe.initialDelaySeconds }}
timeoutSeconds: {{ .Values.readinessProbe.timeoutSeconds }}
resources:
{{ toYaml .Values.serviceSimpleUI.resources | indent 12 }}
{{- with .Values.nodeSelector }}
nodeSelector:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.affinity }}
affinity:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.tolerations }}
tolerations:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- if .Values.securityContext.enabled }}
securityContext:
fsGroup: {{ .Values.securityContext.fsGroup }}
runAsUser: {{ .Values.securityContext.runAsUser }}
{{- if .Values.securityContext.extra }}
{{- toYaml .Values.securityContext.extra | nindent 8 }}
{{- end }}
{{- end }}
4 changes: 2 additions & 2 deletions charts/hawkbit/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ metadata:
spec:
replicas: {{ .Values.replicaCount }}
strategy:
{{- with .Values.updateStrategy }}
{{- with .Values.service.updateStrategy }}
{{- toYaml . | nindent 4 }}
{{- end }}
selector:
Expand All @@ -34,7 +34,7 @@ spec:
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
imagePullPolicy: {{ .Values.image.pullPolicy }}
env:
- name: SPRING_PROFILES_ACTIVE
- name: PROFILES
value: "{{ .Values.spring.profiles }}"
- name: "SPRING_DATASOURCE_URL"
{{- if .Values.env.springDatasourceUrl }}
Expand Down
9 changes: 5 additions & 4 deletions charts/hawkbit/templates/ingress.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{{- if .Values.ingress.enabled -}}
{{- $ingressDefaultPaths := (include "hawkbit.ingressDefaultPaths" $ | fromYamlArray ) }}
{{- $apiVersion := include "hawkbit.ingressAPIVersion" . -}}
{{- $fullName := include "hawkbit.fullname" . -}}
apiVersion: {{ $apiVersion }}
Expand Down Expand Up @@ -30,18 +31,18 @@ spec:
- host: {{ .host | quote }}
http:
paths:
{{- range .paths }}
- path: {{ . }}
{{- range default .paths $ingressDefaultPaths }}
- path: {{ .path }}
{{- if eq $apiVersion "networking.k8s.io/v1" }}
pathType: Prefix
backend:
service:
name: {{ $fullName }}
name: {{ .service }}
port:
name: http
{{- else }}
backend:
serviceName: {{ $fullName }}
serviceName: {{ .service }}
servicePort: http
{{- end }}
{{- end }}
Expand Down
1 change: 1 addition & 0 deletions charts/hawkbit/templates/secrets.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ metadata:
type: Opaque
data:
SPRING_APPLICATION_JSON: {{ .Values.config.secrets | toJson | b64enc }}
SIMPLE_UI_SPRING_APPLICATION_JSON: {{ .Values.config.simpleUI | toJson | b64enc }}
---
apiVersion: v1
kind: Secret
Expand Down
21 changes: 21 additions & 0 deletions charts/hawkbit/templates/servicesimpleui.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
apiVersion: v1
kind: Service
metadata:
name: "{{ include "hawkbit.fullname" . }}-simple-ui"
labels:
app.kubernetes.io/name: "{{ include "hawkbit.name" . }}-simple-ui"
app.kubernetes.io/instance: {{ .Release.Name }}
{{- with .Values.serviceSimpleUI.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
type: {{ .Values.serviceSimpleUI.type }}
ports:
- port: {{ .Values.serviceSimpleUI.port }}
targetPort: http
protocol: TCP
name: http
selector:
app.kubernetes.io/name: "{{ include "hawkbit.name" . }}-simple-ui"
app.kubernetes.io/instance: {{ .Release.Name }}
48 changes: 38 additions & 10 deletions charts/hawkbit/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,14 @@

image:
repository: "hawkbit/hawkbit-update-server"
tag: 0.5.0-mysql
tag: "0.8.0"
pullPolicy: IfNotPresent

simpleUIImage:
repository: "hawkbit/hawkbit-simple-ui"
tag: "0.8.0"
pullPolicy: IfNotPresent

replicaCount: 1

## podDisruptionBudget configuration
podDisruptionBudget:
Expand All @@ -34,27 +38,38 @@
runAsUser: 65534
extra: {}

## strategy used to replace old Pods by new ones
## ref: https://kubernetes.io/docs/concepts/workloads/controllers/deployment/#strategy
updateStrategy:
## default is re-create, because of possible database migrations
type: Recreate

nameOverride: ""
fullnameOverride: ""

service:
type: ClusterIP
port: 80
port: 8080
annotations: {}
replicaCount: 1
## strategy used to replace old Pods by new ones
## ref: https://kubernetes.io/docs/concepts/workloads/controllers/deployment/#strategy
updateStrategy:
## default is re-create, because of possible database migrations
type: Recreate
# traefik.ingress.kubernetes.io/affinity: "true"

serviceSimpleUI:
type: ClusterIP
port: 8088
annotations: {}
replicaCount: 1
updateStrategy:
type: RollingUpdate
resources: {}

livenessProbe:
initialDelaySeconds: 240
timeoutSeconds: 5
readinessProbe:
initialDelaySeconds: 120
failureThreshold: 24
timeoutSeconds: 5
periodSeconds: 5

ingress:
enabled: false
Expand All @@ -64,7 +79,16 @@
# kubernetes.io/tls-acme: "true"
hosts:
- host: hawkbit.local
paths: []
paths:
# default value:
# - path: "/rest"
# service: {{ include "hawkbit.fullname" . }}
# - path: "/swagger-ui"
# service: {{ include "hawkbit.fullname" . }}
# - path: "/v3"
# service: {{ include "hawkbit.fullname" . }}
#² - path: "/"

Check failure on line 90 in charts/hawkbit/values.yaml

View workflow job for this annotation

GitHub Actions / lint-chart

90:6 [comments] missing starting space in comment
# service: {{ include "hawkbit.fullname" . }}-simple-ui
tls: []
# - secretName: hawkbit-tls
# hosts:
Expand All @@ -90,6 +114,9 @@
springRabbitmqUsername: "hawkbit"
springRabbitmqPassword: "hawkbit"

envSimpleUI:
hawkbitServerMgmtUrl: ""

# optional env vars
extraEnv: {}
# JAVA_TOOL_OPTIONS: "-Xms1024m -Xmx1024m"
Expand Down Expand Up @@ -170,6 +197,7 @@
datasource:
username: hawkbit
password: hawkbit
simpleUI: {}


## dependency charts config
Expand Down
Loading