Skip to content

Commit

Permalink
Merge pull request #687 from vholer/chart1
Browse files Browse the repository at this point in the history
Add basic Helm chart values
  • Loading branch information
masa213f authored Jun 10, 2024
2 parents 6b776e8 + 113424a commit a544cfa
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 1 deletion.
3 changes: 3 additions & 0 deletions charts/moco/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,11 @@ $ helm install --create-namespace --namespace moco-system moco -f values.yaml mo

| Key | Type | Default | Description |
| ------------------------- | ------ | --------------------------------------------- | ---------------------------------------------------------------- |
| replicaCount | number | `2` | Number of controller replicas. |
| image.repository | string | `"ghcr.io/cybozu-go/moco"` | MOCO image repository to use. |
| image.pullPolicy | string | `IfNotPresent` | MOCO image pulling policy. |
| image.tag | string | `{{ .Chart.AppVersion }}` | MOCO image tag to use. |
| imagePullSecrets | list | `[]` | Secrets for pulling MOCO image from private repository. |
| resources | object | `{"requests":{"cpu":"100m","memory":"20Mi"}}` | resources used by moco-controller. |
| crds.enabled | bool | `true` | Install and update CRDs as part of the Helm chart. |
| extraArgs | list | `[]` | Additional command line flags to pass to moco-controller binary. |
Expand Down
7 changes: 6 additions & 1 deletion charts/moco/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ metadata:
app.kubernetes.io/component: moco-controller
{{- include "moco.labels" . | nindent 4 }}
spec:
replicas: 2
replicas: {{ .Values.replicaCount }}
selector:
matchLabels:
app.kubernetes.io/component: moco-controller
Expand All @@ -27,6 +27,7 @@ spec:
fieldRef:
fieldPath: metadata.namespace
image: "{{ .Values.image.repository }}:{{ default .Chart.AppVersion .Values.image.tag }}"
imagePullPolicy: {{ .Values.image.pullPolicy }}
livenessProbe:
httpGet:
path: /healthz
Expand Down Expand Up @@ -75,6 +76,10 @@ spec:
runAsNonRoot: true
serviceAccountName: moco-controller-manager
terminationGracePeriodSeconds: 10
{{- with .Values.imagePullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.nodeSelector }}
nodeSelector:
{{- toYaml . | nindent 8 }}
Expand Down
9 changes: 9 additions & 0 deletions charts/moco/values.yaml
Original file line number Diff line number Diff line change
@@ -1,11 +1,20 @@
# replicaCount -- Number of controller replicas.
replicaCount: 2

image:
# image.repository -- MOCO image repository to use.
repository: ghcr.io/cybozu-go/moco

# image.pullPolicy -- MOCO image pulling policy.
pullPolicy: IfNotPresent

# image.tag -- MOCO image tag to use.
# @default -- `{{ .Chart.AppVersion }}`
tag: # 0.20.2

# imagePullSecrets -- Secrets for pulling MOCO image from private repository.
imagePullSecrets: []

# resources -- resources used by moco-controller.
resources:
requests:
Expand Down

0 comments on commit a544cfa

Please sign in to comment.