Skip to content

Commit

Permalink
add hazelcast network
Browse files Browse the repository at this point in the history
  • Loading branch information
philipsens committed Sep 2, 2024
1 parent 180b2c5 commit 3241af8
Show file tree
Hide file tree
Showing 19 changed files with 113 additions and 45 deletions.
2 changes: 1 addition & 1 deletion charts/frank-console/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
apiVersion: v2
name: frank-console
description: The Frank!Framework console is a web application that allows you to manage multiple instances of Frank!Framework from a single console.
version: 0.1.1
version: 0.1.2
appVersion: "8.3.0-SNAPSHOT"
type: application
home: https://frankframework.org
Expand Down
3 changes: 2 additions & 1 deletion charts/frank-console/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ https://hub.docker.com/r/frankframework/frankframework/tags
| `application.security.http.activeDirectory.roleMapping.admin` | Map the role for Admin | `""` |
| `application.security.http.activeDirectory.roleMapping.webService` | Map the role for WebService | `""` |
| `application.security.http.activeDirectory.roleMapping.observer` | Map the role for Observer | `""` |
| `application.environmentVariables` | Set extra environment variables for the Frank! | `{}` |
| `application.javaOpts` | Append custom options to the `JAVA_OPTS` environment variable for the Frank! | `""` |

### frank-console deployment parameters
Expand Down Expand Up @@ -114,7 +115,7 @@ The readiness probe will check if all adapters are running using the server heal
| `ingress.hosts.paths` | Set multiple paths | `undefined` |
| `ingress.hosts.paths.path` | Set path (context url) | `undefined` |
| `ingress.hosts.paths.pathType` | Set type of path | `undefined` |
| `ingress.tls` | Define tls secrets for hosts | `[]` |
| `ingress.tls` | Define tls secrets for hosts | `{}` |

### Other Parameters

Expand Down
10 changes: 7 additions & 3 deletions charts/frank-console/templates/_container.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,16 +34,20 @@ volumeMounts:
subPath: {{ $e.key }}
readOnly: true
{{- end }}
- name: {{ template "frank-console.fullname" . }}-hazelcast-network
mountPath: /app/hazelcast-network.xml
subPath: hazelcast-network.xml
readOnly: true
ports:
- name: hazelcast
containerPort: 5701
protocol: TCP
- name: http
containerPort: 8080
protocol: TCP
- name: https
containerPort: 8443
protocol: TCP
- name: hazelcast
containerPort: 5701
protocol: TCP
- name: multicast
containerPort: 54327
protocol: TCP
Expand Down
4 changes: 4 additions & 0 deletions charts/frank-console/templates/configmap.env.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ metadata:
{{- include "frank-console.labels" . | nindent 4 }}
data:
management.gateway.outbound.class: "org.frankframework.management.gateway.HazelcastOutboundGateway"
hazelcast.network.file: "/app/hazelcast-network.xml"
{{- with .Values.application }}
JAVA_OPTS: "\
{{- with .memory }}
Expand Down Expand Up @@ -41,4 +42,7 @@ data:
{{- end }}
helm.release.version: "{{ $.Chart.Version }}"
container.image: "{{ $.Values.image.registry }}{{ if $.Values.image.registry }}/{{ end }}{{ $.Values.image.repository }}:{{ $.Values.image.tag | default $.Chart.AppVersion }}"
{{- if .environmentVariables }}
{{- toYaml .environmentVariables | nindent 2 }}
{{- end -}}
{{- end -}}
5 changes: 4 additions & 1 deletion charts/frank-console/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -71,4 +71,7 @@ spec:
- key: {{ $e.key }}
path: {{ $e.key }}
defaultMode: 0664
{{- end }}
{{- end }}
- name: {{ template "frank-console.fullname" . }}-hazelcast-network
configMap:
name: {{ .Release.Name }}-hazelcast-network
8 changes: 0 additions & 8 deletions charts/frank-console/values.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -224,14 +224,6 @@
"type": "object",
"description": "Additional annotations for the Ingress resource. To enable certificate autogeneration, place here your cert-manager annotations.",
"default": {}
},
"tls": {
"type": "array",
"description": "Define tls secrets for hosts",
"default": "[]",
"items": {
"type": "string"
}
}
}
},
Expand Down
5 changes: 4 additions & 1 deletion charts/frank-console/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,9 @@ application:
admin: ""
webService: ""
observer: ""
## @param application.environmentVariables [object] Set extra environment variables for the Frank!
##
environmentVariables: { }
## @param application.javaOpts [string] Append custom options to the `JAVA_OPTS` environment variable for the Frank!
##
javaOpts: ""
Expand Down Expand Up @@ -226,7 +229,7 @@ ingress:
paths:
- path: /
pathType: ImplementationSpecific
## @param ingress.tls [array] Define tls secrets for hosts
## @param ingress.tls [object] Define tls secrets for hosts
## e.g.
## tls:
## - secretName: chart-example-tls
Expand Down
6 changes: 3 additions & 3 deletions charts/frank2example/Chart.lock
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
dependencies:
- name: frankframework
repository: file://../frankframework
version: 0.3.1
digest: sha256:5243207f036642eaccf8b0a69a14de716c2c1a4c9faa5c9025500db2ae6deb5b
generated: "2024-08-27T11:16:15.6120901+02:00"
version: 0.3.2
digest: sha256:9964b433c6ea25a6976356e24ec445af22a9dc4916ecaa1773bbab597ea07b95
generated: "2024-09-02T11:04:56.2688498+02:00"
4 changes: 2 additions & 2 deletions charts/frank2example/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
apiVersion: v2
name: frank2example
description: A Helm chart for running Frank2Example on Kubernetes
version: 0.3.0
version: 0.3.1
type: application
home: https://frankframework.org
icon: https://raw.githubusercontent.com/frankframework/charts/master/charts/frank2example/icon.svg
Expand All @@ -11,5 +11,5 @@ keywords:

dependencies:
- name: frankframework
version: 0.3.1
version: 0.3.2
repository: file://../frankframework
28 changes: 15 additions & 13 deletions charts/frank2example/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,19 +38,21 @@ helm delete my-frank2example
This chart is a wrapper for the Frank!Framework chart.
See the documentation for the Frank!Framework chart for more information.

| Name | Description | Value |
| ------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | -------------------------- |
| `frankframework.image.registry` | frank2example image registry | `nexus.frankframework.org` |
| `frankframework.image.repository` | frank2example image repository | `frank2example` |
| `frankframework.image.tag` | frank2example image tag (immutable tags are recommended) | `latest` |
| `frankframework.image.pullPolicy` | frank2example image pull policy | `IfNotPresent` |
| `frankframework.image.pullSecrets` | frank2example image pull secrets | `[]` |
| `frankframework.application.dtap.stage` | Set the `DTAP` stage. Options: `LOC`, `DEV`, `TST`, `ACC`, `PRD` | `LOC` |
| `frankframework.application.resources` | Set Yaml properties for configuring the connections for theFrank!Framework | `{}` |
| `frankframework.application.resources` | Note: If kept empty no resources.yml will be generated, this can be used if the application already has a resources.yml | |
| `frankframework.application.resources` | Note: Not all options will be documented here, please refer to the Frank!Framework documentation for more information. | |
| `frankframework.replicaCount` | Number of Frank!Framework replicas to deploy | `1` |
| `frankframework.securityContext.readOnlyRootFilesystem` | Set the security context for the Frank!Framework containers | `true` |
| Name | Description | Value |
| --------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- | -------------------------- |
| `frankframework.image.registry` | frank2example image registry | `nexus.frankframework.org` |
| `frankframework.image.repository` | frank2example image repository | `frank2example` |
| `frankframework.image.tag` | frank2example image tag (immutable tags are recommended) | `latest` |
| `frankframework.image.pullPolicy` | frank2example image pull policy | `Always` |
| `frankframework.image.pullSecrets` | frank2example image pull secrets | `[]` |
| `frankframework.application.dtap.stage` | Set the `DTAP` stage. Options: `LOC`, `DEV`, `TST`, `ACC`, `PRD` | `TST` |
| `frankframework.application.resources` | Set Yaml properties for configuring the connections for theFrank!Framework | `{}` |
| `frankframework.application.resources` | Note: If kept empty no resources.yml will be generated, this can be used if the application already has a resources.yml | |
| `frankframework.application.resources` | Note: Not all options will be documented here, please refer to the Frank!Framework documentation for more information. | |
| `frankframework.application.properties` | Set Yaml properties for configuring the connections for theFrank!Framework | `{}` |
| `frankframework.application.properties.jdbc.datasource.default` | Set the default datasource | `""` |
| `frankframework.replicaCount` | Number of Frank!Framework replicas to deploy | `1` |
| `frankframework.securityContext.readOnlyRootFilesystem` | Set the security context for the Frank!Framework containers | `true` |

## Configuration and installation details

Expand Down
4 changes: 2 additions & 2 deletions charts/frank2example/values.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
"pullPolicy": {
"type": "string",
"description": "frank2example image pull policy",
"default": "IfNotPresent"
"default": "Always"
},
"pullSecrets": {
"type": "array",
Expand All @@ -45,7 +45,7 @@
"stage": {
"type": "string",
"description": "Set the `DTAP` stage. Options: `LOC`, `DEV`, `TST`, `ACC`, `PRD`",
"default": "LOC"
"default": "TST"
}
}
}
Expand Down
8 changes: 6 additions & 2 deletions charts/frank2example/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ frankframework:
registry: nexus.frankframework.org
repository: frank2example
tag: "latest"
pullPolicy: IfNotPresent
pullPolicy: Always
pullSecrets: []

## @param frankframework.application.dtap.stage Set the `DTAP` stage. Options: `LOC`, `DEV`, `TST`, `ACC`, `PRD`
Expand All @@ -37,12 +37,16 @@ frankframework:
##
application:
dtap:
stage: LOC
stage: TST
resources:
jdbc:
- name: frank2example
type: org.h2.jdbcx.JdbcDataSource
url: jdbc:h2:mem:frank2example;NON_KEYWORDS=VALUE;DB_CLOSE_ON_EXIT=FALSE;DB_CLOSE_DELAY=-1;TRACE_LEVEL_FILE=0;
## @param frankframework.application.properties [object] Set Yaml properties for configuring the connections for theFrank!Framework
## @param frankframework.application.properties.jdbc.datasource.default [string] Set the default datasource
properties:
jdbc.datasource.default: jdbc/frank2example

## @param frankframework.replicaCount Number of Frank!Framework replicas to deploy
##
Expand Down
6 changes: 3 additions & 3 deletions charts/frankframework/Chart.lock
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
dependencies:
- name: frank-console
repository: file://../frank-console
version: 0.1.1
digest: sha256:082a4342c9e88659ecb46c52afb387a139606e19fee0f0dc386440facde9f1dd
generated: "2024-08-27T10:52:19.6053592+02:00"
version: 0.1.2
digest: sha256:71e05fa89823edb1505aef27bb1fad3f6da958ab382b06f778508162cda968a1
generated: "2024-09-02T11:04:53.2461361+02:00"
4 changes: 2 additions & 2 deletions charts/frankframework/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
apiVersion: v2
name: frankframework
description: A Helm chart for running the Frank!Framework on Kubernetes
version: 0.3.1
version: 0.3.2
appVersion: "8.3.0-SNAPSHOT"
type: application
home: https://frankframework.org
Expand All @@ -15,7 +15,7 @@ keywords:

dependencies:
- name: frank-console
version: 0.1.1
version: 0.1.2
alias: console
condition: console.enabled
repository: file://../frank-console
12 changes: 9 additions & 3 deletions charts/frankframework/templates/_container.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -62,16 +62,22 @@ volumeMounts:
subPath: K8sSpecifics.yaml
readOnly: true
{{- end }}
{{- if .Values.console.enabled }}
- name: {{ template "frankframework.fullname" . }}-hazelcast-network
mountPath: /usr/local/tomcat/lib/hazelcast-network.xml
subPath: hazelcast-network.xml
readOnly: true
{{- end }}
ports:
- name: hazelcast
containerPort: 5701
protocol: TCP
- name: http
containerPort: 8080
protocol: TCP
- name: https
containerPort: 8443
protocol: TCP
- name: hazelcast
containerPort: 5701
protocol: TCP
- name: multicast
containerPort: 54327
protocol: TCP
Expand Down
1 change: 1 addition & 0 deletions charts/frankframework/templates/configmap.env.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ metadata:
data:
{{- if .Values.console.enabled }}
management.gateway.inbound.class: "org.frankframework.management.gateway.HazelcastInboundGateway"
hazelcast.network.file: "/usr/local/tomcat/lib/hazelcast-network.xml"
{{- end }}
{{- with .Values.application }}
# Enable Narayana transaction manager
Expand Down
26 changes: 26 additions & 0 deletions charts/frankframework/templates/configmap.hazelcast-network.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
{{/*
ConfigMap for configuring the Hazelcast network
*/}}
{{- if .Values.console.enabled -}}
apiVersion: v1
kind: ConfigMap
metadata:
name: {{ .Release.Name }}-hazelcast-network
labels:
{{- include "frankframework.labels" . | nindent 4 }}
data:
hazelcast-network.xml: |
<?xml version="1.0" encoding="UTF-8"?>
<hazelcast xmlns="http://www.hazelcast.com/schema/config"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.hazelcast.com/schema/config http://www.hazelcast.com/schema/config/hazelcast-config-5.4.xsd">
<network>
<port auto-increment="false">5701</port>
<join>
<multicast enabled="false" />
<kubernetes enabled="true" service-dns="{{ .Release.Name }}-hazelcast.{{ .Release.Namespace }}.svc.cluster.local" />
</join>
</network>
</hazelcast>
{{- end -}}
5 changes: 5 additions & 0 deletions charts/frankframework/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -96,3 +96,8 @@ spec:
configMap:
name: {{ template "frankframework.fullname" . }}-k8s-specifics
{{- end }}
{{- if .Values.console.enabled }}
- name: {{ template "frankframework.fullname" . }}-hazelcast-network
configMap:
name: {{ .Release.Name }}-hazelcast-network
{{- end }}
17 changes: 17 additions & 0 deletions charts/frankframework/templates/service.hazelcast.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{{/* Hazelcast service for the console (this one will be used by the console to connect to the cluster) */}}
{{- if .Values.console.enabled -}}
apiVersion: v1
kind: Service
metadata:
name: {{ .Release.Name }}-hazelcast
labels:
{{- include "frankframework.labels" . | nindent 4 }}
spec:
type: ClusterIP
clusterIP: None
selector:
{{- include "frankframework.selectorLabels" . | nindent 4 }}
ports:
- name: hazelcast
port: 5701
{{- end -}}

0 comments on commit 3241af8

Please sign in to comment.