-
Notifications
You must be signed in to change notification settings - Fork 127
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Refactored Ingress to use one host only (`config.web.external_url` is required) - Added Certificate resource template (secret is mounted to container into `/app/certs/`) - Added support for service with mixed protocols (exposes UI and Wireguard ports on same IP) - Added helm-docs target to makefile - Changed pod labels to use selectorLabels - Removed default probes (app runs without healthy web) - Removed sections from README Signed-off-by: Dmytro Bondar <[email protected]>
- Loading branch information
Showing
14 changed files
with
262 additions
and
257 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
{{/* | ||
Define the service template | ||
{{- include "wg-portal.service" (dict "context" $ "scope" .Values.service.<name> "ports" list "name" "<name>") -}} | ||
*/}} | ||
{{- define "wg-portal.service.tpl" -}} | ||
apiVersion: v1 | ||
kind: Service | ||
metadata: | ||
{{- with .scope.annotations }} | ||
annotations: {{- toYaml . | nindent 4 }} | ||
{{- end }} | ||
labels: {{- include "wg-portal.labels" .context | nindent 4 }} | ||
name: {{ include "wg-portal.fullname" .context }}{{ ternary "" (printf "-%s" .name) (empty .name) }} | ||
spec: | ||
{{- with .scope.clusterIP }} | ||
clusterIP: {{ . }} | ||
{{- end }} | ||
{{- with .scope.externalIPs }} | ||
externalIPs: {{ toYaml . | nindent 4 }} | ||
{{- end }} | ||
{{- with .scope.externalName }} | ||
externalName: {{ . }} | ||
{{- end }} | ||
{{- with .scope.externalTrafficPolicy }} | ||
externalTrafficPolicy: {{ . }} | ||
{{- end }} | ||
{{- with .scope.healthCheckNodePort }} | ||
healthCheckNodePort: {{ . }} | ||
{{- end }} | ||
{{- with .scope.loadBalancerIP }} | ||
loadBalancerIP: {{ . }} | ||
{{- end }} | ||
{{- with .scope.loadBalancerSourceRanges }} | ||
loadBalancerSourceRanges: {{ toYaml . | nindent 4 }} | ||
{{- end }} | ||
ports: {{- toYaml .ports | nindent 4 }} | ||
{{- with .scope.publishNotReadyAddresses }} | ||
publishNotReadyAddresses: {{ . }} | ||
{{- end }} | ||
{{- with .scope.sessionAffinity }} | ||
sessionAffinity: {{ . }} | ||
{{- end }} | ||
{{- with .scope.sessionAffinityConfig }} | ||
sessionAffinityConfig: {{ toYaml . | nindent 4 }} | ||
{{- end }} | ||
{{- with .scope.topologyKeys }} | ||
topologyKeys: {{ toYaml . | nindent 4 }} | ||
{{- end }} | ||
{{- with .scope.type }} | ||
type: {{ . }} | ||
{{- end }} | ||
selector: {{- include "wg-portal.selectorLabels" .context | nindent 4 }} | ||
{{- end -}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
{{/* https://cert-manager.io/docs/usage/certificate/#creating-certificate-resources */}} | ||
{{- if and .Values.certificate.enabled (include "wg-portal.hostname" .) -}} | ||
apiVersion: cert-manager.io/v1 | ||
kind: Certificate | ||
metadata: | ||
name: {{ include "wg-portal.fullname" . }} | ||
labels: {{- include "wg-portal.labels" . | nindent 4 }} | ||
spec: | ||
secretName: {{ include "wg-portal.fullname" . }}-tls | ||
{{- with .Values.certificate.secretTemplate }} | ||
secretTemplate: {{ toYaml . | nindent 4 }} | ||
{{- end }} | ||
{{- with .Values.certificate.privateKey }} | ||
privateKey: {{- toYaml . | nindent 4 }} | ||
{{- end }} | ||
{{- with .Values.certificate.keystores }} | ||
keystores: {{- toYaml . | nindent 4 }} | ||
{{- end }} | ||
{{- with .Values.certificate.duration }} | ||
duration: {{ . }} | ||
{{- end }} | ||
{{- with .Values.certificate.renewBefore }} | ||
renewBefore: {{ . }} | ||
{{- end }} | ||
{{- with .Values.certificate.usages }} | ||
usages: {{- toYaml . | nindent 4 }} | ||
{{- end }} | ||
{{- with .Values.certificate.subject }} | ||
subject: {{- toYaml . | nindent 4 }} | ||
{{- end }} | ||
{{- with .Values.certificate.commonName }} | ||
commonName: {{ . }} | ||
{{- end }} | ||
dnsNames: | ||
- {{ include "wg-portal.hostname" . }} | ||
{{- with .Values.certificate.uris }} | ||
uris: {{- toYaml . | nindent 4 }} | ||
{{- end }} | ||
{{- with .Values.certificate.emailAddresses }} | ||
emailAddresses: {{- toYaml . | nindent 4 }} | ||
{{- end }} | ||
{{- with .Values.certificate.ipAddresses }} | ||
ipAddresses: {{- toYaml . | nindent 4 }} | ||
{{- end }} | ||
{{- with .Values.certificate.otherNames }} | ||
otherNames: {{- toYaml . | nindent 4 }} | ||
{{- end }} | ||
issuerRef: | ||
{{- with .Values.certificate.issuer.group }} | ||
group: {{ . }} | ||
{{- end }} | ||
kind: {{ .Values.certificate.issuer.kind }} | ||
name: {{ .Values.certificate.issuer.name }} | ||
{{- end -}} |
Oops, something went wrong.