diff --git a/Dockerfile b/Dockerfile index 046a84b..6d18608 100644 --- a/Dockerfile +++ b/Dockerfile @@ -59,6 +59,8 @@ RUN addgroup --gid 1001 dev && \ # Adjust permissions for /usr/local and home directories RUN chown -R dev:dev /usr/local /home/dev +RUN echo "+:dev:ALL" >> /etc/security/access.conf + # Switch to non-root user USER dev diff --git a/chart/templates/cm-entrypoint.yaml b/chart/templates/cm-entrypoint.yaml index efe562d..8a2cc66 100644 --- a/chart/templates/cm-entrypoint.yaml +++ b/chart/templates/cm-entrypoint.yaml @@ -30,7 +30,7 @@ data: echo "Starting SSH service with host keys from /home/dev/ssh_keys on port 2222." - /usr/sbin/sshd -D -e -f /etc/ssh/sshd_config \ + /usr/sbin/sshd -D -ddd -e -f /etc/ssh/sshd_config \ -o Port={{ .Values.service.targetPort }} \ -o HostKey=/home/dev/ssh_keys/ssh_host_rsa_key \ -o HostKey=/home/dev/ssh_keys/ssh_host_ecdsa_key \ diff --git a/chart/templates/cm-sshconfig.yaml b/chart/templates/cm-sshconfig.yaml index d511f94..8f2c965 100644 --- a/chart/templates/cm-sshconfig.yaml +++ b/chart/templates/cm-sshconfig.yaml @@ -14,4 +14,4 @@ data: AcceptEnv LANG LC_* Subsystem sftp /usr/lib/openssh/sftp-server UseDNS no - PidFile /home/dev/run/sshd.pid + PidFile /home/dev/run/sshd.pid \ No newline at end of file diff --git a/chart/templates/cm-sshkeys.yaml b/chart/templates/cm-sshkeys.yaml index fc88e8b..a0c299d 100644 --- a/chart/templates/cm-sshkeys.yaml +++ b/chart/templates/cm-sshkeys.yaml @@ -4,5 +4,4 @@ metadata: name: {{ .Release.Name }}-ssh-keys data: authorized_keys: |- - {{ .Values.ssh.authorizedKeys | nindent 4 }} - ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDBMGGOs2OYGxj74/TS3AXmbGNoVLQ07gCG5LXamlrd6HoZLPRkqwy2X1YS+9mWvINwH7FzvPnzd+5P5fxeLiYiwTIEXamlqQ53rnTvvgtS9Wl7fI/4MdlI2pNsAS3jm1KOzn/w5ABTkvGUo9QtzgR2659ykpo/LicsShEqVKh0ItOv+D298JsD5Ykj9Y3S5GE4D84DGisBpvBxdkMWm3ZD4SYML4b/P2ihFL3IEdmPfewS7O37bpAe4TuhjltOmTBjy4QaQgQacMDXkz5WCrCYh3N2/2gmsPLR5lirH9YJLzyGR08uhsyFMe79Rxl+Fs+9UDvx5hcVjXMUOnO34G3fTu54OTcekN+h7l+6rLWuSuiRH0O+RIV3PvlT+ibOiRPwfWSWDQtMTTynRrYMKEtnFr/Eg0EtdQRzFhrwxwX9+zaAgAcmL/3qIDSzEwOWm6pVH1RNKjC9K8pDu9mKmD6zKFfkqsMh9aV6N+mSTcDnLfMRD9xYWSbJnH2Xj3c3uskJ2XsGDdHoxIQvx2KfStaGshN83mzbvn9Qx3SwdI2X/lpABIrrSg97kNKWPywB8s5J3a86Y+Knvd8fSz3lM/2Yk1lZ9oYN68wD0mqNmPbxIMQVaKh1pd4xTucVM+1E+IEKFk8Un6xNRk0luYanbGjvYpN5gxnEfq4NT1+VhKrcHw== marcel zapf@DESKTOP-CR0CINF + {{ .Values.ssh.authorizedKeys | nindent 4 }} \ No newline at end of file diff --git a/chart/values.yaml b/chart/values.yaml index 9195c4c..adc3ed8 100644 --- a/chart/values.yaml +++ b/chart/values.yaml @@ -1,7 +1,7 @@ replicaCount: 1 image: - source: ghcr.io/syntax3rror404/k8s-devmachine@sha256:9d7bf6ca64f090c46c1bb85fe406a75111ef59207ca6548b72a10f3b5ff3f2a5 + source: ghcr.io/syntax3rror404/k8s-devmachine@sha256:b25b3089bece565cf372eb90ac4302db4decbf57af2ee67b6e09df2fa7438d66 pullPolicy: IfNotPresent service: