Skip to content

Commit 55c7bd3

Browse files
committed
add NOTES for cloud manager
1 parent c19a0c8 commit 55c7bd3

File tree

4 files changed

+151
-47
lines changed

4 files changed

+151
-47
lines changed

charts/gorse-manager/README.md

Lines changed: 28 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,11 @@ This starts an HTTP proxy for secure access to the Gorse Manager Dashboard. Visi
4747

4848
### Global parameters
4949

50-
50+
| Name | Description | Value |
51+
| ------------------------- | ----------------------------------------------- | ----- |
52+
| `global.imageRegistry` | Global Docker image registry | `""` |
53+
| `global.imagePullSecrets` | Global Docker registry secret names as an array | `[]` |
54+
| `global.storageClass` | Global StorageClass for Persistent Volume(s) | `""` |
5155

5256

5357
### Common parameters
@@ -68,7 +72,7 @@ This starts an HTTP proxy for secure access to the Gorse Manager Dashboard. Visi
6872
| Name | Description | Value |
6973
| ---------------------------------- | -------------------------------------------------------------------------------------------------------------------------------- | ------------------------- |
7074
| `database` | URI used to connect Gorse manager to the database for user data. | `""` |
71-
| `service.type` | Gorse Manager service type | `LoadBalancer` |
75+
| `service.type` | Gorse Manager service type | `ClusterIP` |
7276
| `service.ports.http` | Gorse Manager service HTTP port | `80` |
7377
| `service.ports.https` | Gorse Manager service HTTPS port | `443` |
7478
| `service.httpsTargetPort` | Target port for HTTPS | `https` |
@@ -103,11 +107,6 @@ This starts an HTTP proxy for secure access to the Gorse Manager Dashboard. Visi
103107
| `image.digest` | Gorse Manager image digest in the way sha256:aa.... Please note this parameter, if set, will override the tag | `""` |
104108
| `image.pullPolicy` | Gorse Manager image pull policy | `IfNotPresent` |
105109
| `image.pullSecrets` | Specify docker-registry secret names as an array | `[]` |
106-
| `autoscaling.enabled` | Enable replica autoscaling settings | `false` |
107-
| `autoscaling.minReplicas` | Minimum replicas for the pod autoscaling | `1` |
108-
| `autoscaling.maxReplicas` | Maximum replicas for the pod autoscaling | `11` |
109-
| `autoscaling.targetCPU` | Percentage of CPU to consider when autoscaling | `""` |
110-
| `autoscaling.targetMemory` | Percentage of Memory to consider when autoscaling | `""` |
111110
| `podAffinityPreset` | Pod affinity preset. Ignored if `server.affinity` is set. Allowed values: `soft` or `hard` | `""` |
112111
| `podAntiAffinityPreset` | Pod anti-affinity preset. Ignored if `server.affinity` is set. Allowed values: `soft` or `hard` | `soft` |
113112
| `nodeAffinityPreset.type` | Node affinity preset type. Ignored if `server.affinity` is set. Allowed values: `soft` or `hard` | `""` |
@@ -118,14 +117,28 @@ This starts an HTTP proxy for secure access to the Gorse Manager Dashboard. Visi
118117
| `tolerations` | Tolerations for Gorse server pods assignment | `[]` |
119118

120119

121-
### MongoDB® Parameters
122-
123-
| Name | Description | Value |
124-
| --------------------------- | ------------------------------------------------------- | ------------ |
125-
| `mongodb.enabled` | Switch to enable or disable the MongoDB helm chart | `true` |
126-
| `mongodb.auth.enabled` | Enable authentication | `false` |
127-
| `mongodb.auth.rootPassword` | MongoDB(®) root password | `""` |
128-
| `mongodb.architecture` | MongoDB(®) architecture (`standalone`` or `replicaset`) | `standalone` |
120+
### Database Parameters
121+
122+
| Name | Description | Value |
123+
| -------------------------------------------- | ------------------------------------------------------------------------- | ------------------- |
124+
| `mongodb.enabled` | Deploy a MongoDB server to satisfy the applications database requirements | `true` |
125+
| `mongodb.architecture` | MongoDB(®) architecture (`standalone` or `replicaset`) | `standalone` |
126+
| `mongodb.auth.rootUser` | MongoDB(®) root user | `root` |
127+
| `mongodb.auth.rootPassword` | MongoDB(®) root password | `""` |
128+
| `mongodb.auth.username` | Custom user to be created during the initialization | `gorse` |
129+
| `mongodb.auth.password` | Password for the custom users set at `auth.usernames` | `""` |
130+
| `mongodb.auth.database` | Custom databases to be created during the initialization | `gorse` |
131+
| `mongodb.persistence.enabled` | Enable MongoDB(®) data persistence using PVC | `true` |
132+
| `mongodb.persistence.storageClass` | PVC Storage Class for MongoDB(®) data volume | `""` |
133+
| `mongodb.persistence.accessModes` | PV Access Mode | `["ReadWriteOnce"]` |
134+
| `mongodb.persistence.size` | PVC Storage Request for MongoDB(®) data volume | `8Gi` |
135+
| `externalDatabase.host` | Database host | `localhost` |
136+
| `externalDatabase.port` | Database port number | `27017` |
137+
| `externalDatabase.username` | Non-root username for Gorse | `gorse` |
138+
| `externalDatabase.password` | Password for the non-root username for Gorse | `""` |
139+
| `externalDatabase.database` | Gorse database name | `gorse` |
140+
| `externalDatabase.existingSecret` | Name of an existing secret resource containing the database credentials | `""` |
141+
| `externalDatabase.existingSecretPasswordKey` | Name of an existing secret key containing the database credentials | `mongodb-passwords` |
129142

130143

131144
### MySQL Parameters
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
CHART NAME: {{ .Chart.Name }}
2+
CHART VERSION: {{ .Chart.Version }}
3+
APP VERSION: {{ .Chart.AppVersion }}
4+
5+
** Please be patient while the chart is being deployed **
6+
7+
{{- if .Values.ingress.enabled }}
8+
9+
1. Get the Gorse manager URL and associate hostname to your cluster external IP:
10+
11+
export CLUSTER_IP=$(minikube ip) # On Minikube. Use: `kubectl cluster-info` on others K8s clusters
12+
echo "Gorse dashboard URL: http{{ if .Values.ingress.tls }}s{{ end }}://{{ .Values.ingress.hostname }}/"
13+
echo "$CLUSTER_IP {{ .Values.ingress.hostname }}" | sudo tee -a /etc/hosts
14+
15+
{{- else }}
16+
{{- $port := .Values.service.ports.http | toString }}
17+
18+
1. Get the Gorse manager URL by running these commands:
19+
20+
{{- if contains "NodePort" .Values.service.type }}
21+
22+
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "common.names.fullname" . }})
23+
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
24+
echo "Gorse dashboard URL: http://$NODE_IP:$NODE_PORT/"
25+
26+
{{- else if contains "LoadBalancer" .Values.service.type }}
27+
28+
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
29+
Watch the status with: 'kubectl get svc --namespace {{ .Release.Namespace }} -w {{ include "common.names.fullname" . }}'
30+
31+
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "common.names.fullname" . }} --template "{{ "{{ range (index .status.loadBalancer.ingress 0) }}{{ . }}{{ end }}" }}")
32+
echo "Gorse dashboard URL: http://$SERVICE_IP{{- if ne $port "80" }}:{{ .Values.service.ports.http }}{{ end }}/"
33+
34+
{{- else if contains "ClusterIP" .Values.service.type }}
35+
36+
kubectl port-forward --namespace {{ .Release.Namespace }} svc/{{ include "common.names.fullname" . }} {{ .Values.service.ports.http }}:{{ .Values.service.ports.http }} &
37+
echo "Gorse dashboard URL: http://127.0.0.1{{- if ne $port "80" }}:{{ .Values.service.ports.http }}{{ end }}/"
38+
39+
{{- end }}
40+
{{- end }}

charts/gorse-manager/templates/deployment.yaml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,6 @@ metadata:
1212
annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }}
1313
{{- end }}
1414
spec:
15-
{{- if not .Values.autoscaling.enabled }}
16-
replicas: {{ .Values.replicaCount }}
17-
{{- end }}
1815
selector:
1916
matchLabels: {{- include "common.labels.matchLabels" . | nindent 6 }}
2017
app.kubernetes.io/component: manager

charts/gorse-manager/values.yaml

Lines changed: 83 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,21 @@
11
## @section Global parameters
2+
## Global Docker image parameters
3+
## Please, note that this will override the image parameters, including dependencies, configured to use the global value
4+
## Current available global Docker image parameters: imageRegistry, imagePullSecrets and storageClass
5+
##
6+
7+
## @param global.imageRegistry Global Docker image registry
8+
## @param global.imagePullSecrets Global Docker registry secret names as an array
9+
## @param global.storageClass Global StorageClass for Persistent Volume(s)
10+
##
11+
global:
12+
imageRegistry: ""
13+
## E.g.
14+
## imagePullSecrets:
15+
## - myRegistryKeySecretName
16+
##
17+
imagePullSecrets: []
18+
storageClass: ""
219

320
## @section Common parameters
421
##
@@ -36,7 +53,7 @@ database: ""
3653
service:
3754
## @param service.type Gorse Manager service type
3855
##
39-
type: LoadBalancer
56+
type: ClusterIP
4057
## @param service.ports.http Gorse Manager service HTTP port
4158
## @param service.ports.https Gorse Manager service HTTPS port
4259
##
@@ -231,25 +248,6 @@ image:
231248
##
232249
pullSecrets: []
233250

234-
## Autoscaling configuration
235-
##
236-
autoscaling:
237-
## @param autoscaling.enabled Enable replica autoscaling settings
238-
##
239-
enabled: false
240-
## @param autoscaling.minReplicas Minimum replicas for the pod autoscaling
241-
##
242-
minReplicas: 1
243-
## @param autoscaling.maxReplicas Maximum replicas for the pod autoscaling
244-
##
245-
maxReplicas: 11
246-
## @param autoscaling.targetCPU Percentage of CPU to consider when autoscaling
247-
##
248-
targetCPU: ""
249-
## @param autoscaling.targetMemory Percentage of Memory to consider when autoscaling
250-
##
251-
targetMemory: ""
252-
253251
## @param podAffinityPreset Pod affinity preset. Ignored if `server.affinity` is set. Allowed values: `soft` or `hard`
254252
## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#inter-pod-affinity-and-anti-affinity
255253
##
@@ -289,21 +287,77 @@ nodeSelector: {}
289287
##
290288
tolerations: []
291289

292-
## @section MongoDB® Parameters
290+
## @section Database Parameters
291+
##
293292

294-
## MongoDB® chart configuration
295-
## ref: https://github.com/bitnami/charts/tree/main/bitnami/mongodb
296-
## @param mongodb.enabled Switch to enable or disable the MongoDB helm chart
297-
## @param mongodb.auth.enabled Enable authentication
298-
## @param mongodb.auth.rootPassword MongoDB(®) root password
299-
## @param mongodb.architecture MongoDB(®) architecture (`standalone`` or `replicaset`)
293+
## MongoDB chart configuration
294+
## ref: https://github.com/bitnami/charts/blob/main/bitnami/mongodb/values.yaml
300295
##
301296
mongodb:
297+
## @param mongodb.enabled Deploy a MongoDB server to satisfy the applications database requirements
298+
##
302299
enabled: true
300+
## @param mongodb.architecture MongoDB(®) architecture (`standalone` or `replicaset`)
301+
##
302+
architecture: standalone
303+
## MongoDB(®) Authentication parameters
304+
##
303305
auth:
304-
enabled: false
306+
## @param mongodb.auth.rootUser MongoDB(®) root user
307+
##
308+
rootUser: "root"
309+
## @param mongodb.auth.rootPassword MongoDB(®) root password
310+
## ref: https://github.com/bitnami/containers/tree/main/bitnami/mongodb#setting-the-root-user-and-password-on-first-run
311+
##
305312
rootPassword: ""
306-
architecture: "standalone"
313+
## MongoDB(®) custom users and databases
314+
## ref: https://github.com/bitnami/containers/tree/main/bitnami/mongodb#creating-a-user-and-database-on-first-run
315+
## @param mongodb.auth.username Custom user to be created during the initialization
316+
## @param mongodb.auth.password Password for the custom users set at `auth.usernames`
317+
## @param mongodb.auth.database Custom databases to be created during the initialization
318+
##
319+
username: gorse
320+
password: ""
321+
database: gorse
322+
## Enable persistence using Persistent Volume Claims
323+
## ref: https://kubernetes.io/docs/user-guide/persistent-volumes/
324+
##
325+
persistence:
326+
## @param mongodb.persistence.enabled Enable MongoDB(®) data persistence using PVC
327+
##
328+
enabled: true
329+
## @param mongodb.persistence.storageClass PVC Storage Class for MongoDB(®) data volume
330+
## If defined, storageClassName: <storageClass>
331+
## If set to "-", storageClassName: "", which disables dynamic provisioning
332+
## If undefined (the default) or set to null, no storageClassName spec is
333+
## set, choosing the default provisioner.
334+
##
335+
storageClass: ""
336+
## @param mongodb.persistence.accessModes PV Access Mode
337+
##
338+
accessModes:
339+
- ReadWriteOnce
340+
## @param mongodb.persistence.size PVC Storage Request for MongoDB(&reg;) data volume
341+
##
342+
size: 8Gi
343+
## External MongoDB configuration
344+
## All of these values are only used when mongodb.enabled is set to false
345+
## @param externalDatabase.host Database host
346+
## @param externalDatabase.port Database port number
347+
## @param externalDatabase.username Non-root username for Gorse
348+
## @param externalDatabase.password Password for the non-root username for Gorse
349+
## @param externalDatabase.database Gorse database name
350+
## @param externalDatabase.existingSecret Name of an existing secret resource containing the database credentials
351+
## @param externalDatabase.existingSecretPasswordKey Name of an existing secret key containing the database credentials
352+
##
353+
externalDatabase:
354+
host: localhost
355+
port: 27017
356+
username: gorse
357+
database: gorse
358+
password: ""
359+
existingSecret: ""
360+
existingSecretPasswordKey: "mongodb-passwords"
307361

308362
## @section MySQL Parameters
309363

0 commit comments

Comments
 (0)