Skip to content

Commit

Permalink
fix(scaleway-certmanager-webhook): invalid podLabels and format (#18)
Browse files Browse the repository at this point in the history
  • Loading branch information
Nox-404 authored May 14, 2024
1 parent 9252fa4 commit f59c9e1
Show file tree
Hide file tree
Showing 3 changed files with 37 additions and 34 deletions.
2 changes: 1 addition & 1 deletion charts/scaleway-certmanager-webhook/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ apiVersion: v2
appVersion: "v0.1.0"
description: Cert-Manager webhook for Scaleway
name: scaleway-certmanager-webhook
version: 0.2.0
version: 0.2.1
35 changes: 18 additions & 17 deletions charts/scaleway-certmanager-webhook/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Deploys the scaleway cert-manager webhook.

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

## Installing the Chart

Expand Down Expand Up @@ -34,20 +34,21 @@ Configuration parameters.

Common parameters.

| Name | Description | Value |
| ------------------------ | ------------------------------------------------- | ---------------------------------------- |
| `nameOverride` | Override charts name | `""` |
| `fullnameOverride` | Override charts and release name | `""` |
| `replicaCount` | Number of replica | `1` |
| `image.repository` | Repository for the webhook image | `scaleway/cert-manager-webhook-scaleway` |
| `image.pullPolicy` | Image pull policy | `IfNotPresent` |
| `image.imagePullSecrets` | Image pull secrets | `[]` |
| `image.tag` | Tag for the webhook image, defaults to AppVersion | `""` |
| `service.type` | Service type exposing the webhook | `ClusterIP` |
| `service.port` | Service port exposing the webhook | `443` |
| `resources` | Resources definition | `{}` |
| `podLabels` | Pod labels definition | `{}` |
| `nodeSelector` | Node selector | `{}` |
| `tolerations` | Tolerations | `[]` |
| `affinity` | Affinities | `{}` |
| Name | Description | Value |
| ------------------------ | ------------------------------------------------------------------ | ---------------------------------------- |
| `nameOverride` | Override charts name | `""` |
| `fullnameOverride` | Override charts and release name | `""` |
| `replicaCount` | Number of replica | `1` |
| `image.repository` | Repository for the webhook image | `scaleway/cert-manager-webhook-scaleway` |
| `image.pullPolicy` | Image pull policy | `IfNotPresent` |
| `image.imagePullSecrets` | Image pull secrets | `[]` |
| `image.tag` | Tag for the webhook image, defaults to AppVersion | `""` |
| `extraEnv` | Additional environment variables to pass to the webhook deployment | `[]` |
| `service.type` | Service type exposing the webhook | `ClusterIP` |
| `service.port` | Service port exposing the webhook | `443` |
| `resources` | Resources definition | `{}` |
| `podLabels` | Pod labels | `{}` |
| `nodeSelector` | Node selector | `{}` |
| `tolerations` | Tolerations | `[]` |
| `affinity` | Affinities | `{}` |

34 changes: 18 additions & 16 deletions charts/scaleway-certmanager-webhook/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ spec:
app: {{ include "scaleway-webhook.name" . }}
release: {{ .Release.Name }}
{{- with .Values.podLabels }}
{{ toYaml .Values.podLabels | indent 8 }}
{{- toYaml . | nindent 8 }}
{{- end }}
spec:
serviceAccountName: {{ include "scaleway-webhook.fullname" . }}
Expand All @@ -37,14 +37,14 @@ spec:
env:
- name: GROUP_NAME
value: {{ .Values.groupName | quote }}
{{- with .Values.extraEnv }}
{{- toYaml . | nindent 12 }}
{{- end }}
{{ if and .Values.secret.accessKey .Values.secret.secretKey }}
{{- with .Values.extraEnv }}
{{- toYaml . | nindent 12 }}
{{- end }}
{{- if and .Values.secret.accessKey .Values.secret.secretKey }}
envFrom:
- secretRef:
name: {{ .Values.secret.name }}
{{ end }}
{{- end }}
ports:
- name: https
containerPort: 443
Expand All @@ -64,21 +64,23 @@ spec:
- name: certs
mountPath: /tls
readOnly: true
{{- with .Values.resources }}
resources:
{{ toYaml .Values.resources | indent 12 }}
{{- toYaml . | nindent 12 }}
{{- end }}
volumes:
- name: certs
secret:
secretName: {{ include "scaleway-webhook.servingCertificate" . }}
{{- with .Values.nodeSelector }}
{{- with .Values.nodeSelector }}
nodeSelector:
{{ toYaml . | indent 8 }}
{{- end }}
{{- with .Values.affinity }}
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.affinity }}
affinity:
{{ toYaml . | indent 8 }}
{{- end }}
{{- with .Values.tolerations }}
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.tolerations }}
tolerations:
{{ toYaml . | indent 8 }}
{{- end }}
{{- toYaml . | nindent 8 }}
{{- end }}

0 comments on commit f59c9e1

Please sign in to comment.