From f5d74a2d5e4458d787f112c1ebcd4681e1709af2 Mon Sep 17 00:00:00 2001 From: Stavros Kois <47820033+stavros-k@users.noreply.github.com> Date: Wed, 2 Feb 2022 22:18:53 +0200 Subject: [PATCH] fix(unifi): run as non-root (#1831) * fix(unifi): run as non-root * remove as its default --- charts/stable/unifi/Chart.yaml | 2 +- charts/stable/unifi/questions.yaml | 13 +++---------- charts/stable/unifi/values.yaml | 12 +++--------- 3 files changed, 7 insertions(+), 20 deletions(-) diff --git a/charts/stable/unifi/Chart.yaml b/charts/stable/unifi/Chart.yaml index 00d4ebda9dd..e3af9ef7e1a 100644 --- a/charts/stable/unifi/Chart.yaml +++ b/charts/stable/unifi/Chart.yaml @@ -21,7 +21,7 @@ sources: - https://github.com/jacobalberty/unifi-docker - https://unifi-network.ui.com type: application -version: 9.0.41 +version: 9.0.42 annotations: truecharts.org/catagories: | - Networking diff --git a/charts/stable/unifi/questions.yaml b/charts/stable/unifi/questions.yaml index 90b04f329cd..2fea0e68ed2 100644 --- a/charts/stable/unifi/questions.yaml +++ b/charts/stable/unifi/questions.yaml @@ -82,13 +82,6 @@ questions: type: dict attrs: # Include{fixedEnv} - - variable: PUID - label: "PUID" - description: "Sets the PUID env var for LinuxServer.io (compatible) containers" - schema: - type: int - default: 568 - # Include{containerConfig} @@ -556,7 +549,7 @@ questions: label: "runAsNonRoot" schema: type: boolean - default: false + default: true # Include{securityContextAdvanced} - variable: podSecurityContext @@ -571,13 +564,13 @@ questions: description: "The UserID of the user running the application" schema: type: int - default: 0 + default: 999 - variable: runAsGroup label: "runAsGroup" description: The groupID this App of the user running the application" schema: type: int - default: 0 + default: 999 - variable: fsGroup label: "fsGroup" description: "The group that should own ALL storage." diff --git a/charts/stable/unifi/values.yaml b/charts/stable/unifi/values.yaml index 9871379dc46..8a9931fe53c 100644 --- a/charts/stable/unifi/values.yaml +++ b/charts/stable/unifi/values.yaml @@ -48,18 +48,12 @@ service: securityContext: readOnlyRootFilesystem: false - runAsNonRoot: false podSecurityContext: - runAsGroup: 0 - runAsUser: 0 + runAsGroup: 999 + runAsUser: 999 -env: - # TZ: - PUID: 568 - # Permissions Settings - UNIFI_GID: "{{ .Values.env.PUID }}" - UNIFI_UID: "{{ .Values.podSecurityContext.fsGroup }}" +env: {} persistence: config: