fix(vpn): don't do anything with config file if type is tailscale (#210)

* fix(vpn): don't do anything with config file if type is tailscale

* remove extra )

* remove extra )
This commit is contained in:
Stavros Kois
2022-08-25 01:50:55 +03:00
committed by GitHub
parent 8f62096ba2
commit eadfe2d5fc
3 changed files with 6 additions and 4 deletions

View File

@@ -15,4 +15,4 @@ maintainers:
name: common
sources: null
type: library
version: 10.5.0
version: 10.5.1

View File

@@ -16,7 +16,9 @@ It will include / inject the required templates based on the given values.
{{- include "tc.common.addon.tailscale" . }}
{{- end -}}
{{- $_ := set .Values.persistence "vpnconfig" .Values.addons.vpn.configFile -}}
{{- if ne "tailscale" .Values.addons.vpn.type -}}
{{- $_ := set .Values.persistence "vpnconfig" .Values.addons.vpn.configFile -}}
{{- end -}}
{{- end -}}
{{- end -}}

View File

@@ -86,7 +86,7 @@ before chart installation.
- |
/bin/bash <<'EOF'
echo "Automatically correcting permissions..."
{{- if and ( .Values.addons.vpn.configFile.enabled ) ( not ( eq .Values.addons.vpn.type "disabled" )) }}
{{- if and ( .Values.addons.vpn.configFile.enabled ) ( ne .Values.addons.vpn.type "disabled" ) ( ne .Values.addons.vpn.type "tailscale" ) }}
echo "Automatically correcting permissions for vpn config file..."
if nfs4xdr_getfacl && nfs4xdr_getfacl | grep -qv "Failed to get NFSv4 ACL"; then
echo "NFSv4 ACLs detected, using nfs4_setfacl to set permissions..."
@@ -187,7 +187,7 @@ before chart installation.
subPath: {{ $hpm.subPath }}
{{- end }}
{{- end }}
{{- if and ( .Values.addons.vpn.configFile.enabled ) ( not ( eq .Values.addons.vpn.type "disabled" )) }}
{{- if and ( .Values.addons.vpn.configFile.enabled ) ( ne .Values.addons.vpn.type "disabled" ) ( ne .Values.addons.vpn.type "tailsacale" ) }}
- name: vpnconfig
mountPath: /vpn/vpn.conf
{{- end }}