[common] allow code-server to run with additional args (#414)

This commit is contained in:
Jeff Billimek 2020-12-18 09:44:57 -05:00 committed by GitHub
parent 1252387702
commit b0d6043893
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 18 additions and 3 deletions

View File

@ -4,6 +4,12 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [2.1.0]
### Added
- Allow for additional arguments to be added to code-server runtime via `addons.codeserver.args`
## [2.0.4] ## [2.0.4]
### Fixed ### Fixed

View File

@ -2,7 +2,7 @@ apiVersion: v2
name: common name: common
description: Function library for k8s-at-home charts description: Function library for k8s-at-home charts
type: library type: library
version: 2.0.4 version: 2.1.0
keywords: keywords:
- k8s-at-home - k8s-at-home
- common - common

View File

@ -24,10 +24,11 @@ ports:
containerPort: {{ .Values.addons.codeserver.service.port.port }} containerPort: {{ .Values.addons.codeserver.service.port.port }}
protocol: TCP protocol: TCP
args: args:
{{- range .Values.addons.codeserver.args }}
- {{ . | quote }}
{{- end }}
- "--port" - "--port"
- "{{ .Values.addons.codeserver.service.port.port }}" - "{{ .Values.addons.codeserver.service.port.port }}"
- "--auth"
- "none"
- {{ .Values.addons.codeserver.workingDir | default (first .Values.addons.codeserver.volumeMounts).mountPath }} - {{ .Values.addons.codeserver.workingDir | default (first .Values.addons.codeserver.volumeMounts).mountPath }}
{{- with .Values.addons.codeserver.volumeMounts }} {{- with .Values.addons.codeserver.volumeMounts }}
volumeMounts: volumeMounts:

View File

@ -314,6 +314,14 @@ addons:
pullPolicy: IfNotPresent pullPolicy: IfNotPresent
tag: 3.7.4 tag: 3.7.4
# Set codeserver command line arguments
# consider setting --user-data-dir to a persistent location to preserve code-server setting changes
args:
- --auth
- none
# - --user-data-dir
# - "/config/.vscode"
# Specify a list of volumes that get mounted in the code-server container. # Specify a list of volumes that get mounted in the code-server container.
# At least 1 volumeMount is required! # At least 1 volumeMount is required!
volumeMounts: [] volumeMounts: []