Skip to content

Commit 9208e84

Browse files
author
Software Releases | The Pins Team
committed
chore(helm-charts): Update package repo index and update charts
Signed-off-by: Software Releases | The Pins Team <[email protected]>
1 parent 05b0f68 commit 9208e84

File tree

13 files changed

+750
-0
lines changed

13 files changed

+750
-0
lines changed

charts/upstream/.helmignore

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# Patterns to ignore when building packages.
2+
# This supports shell glob matching, relative path matching, and
3+
# negation (prefixed with !). Only one pattern per line.
4+
.DS_Store
5+
# Common VCS dirs
6+
.git/
7+
.gitignore
8+
.bzr/
9+
.bzrignore
10+
.hg/
11+
.hgignore
12+
.svn/
13+
# Common backup files
14+
*.swp
15+
*.bak
16+
*.tmp
17+
*.orig
18+
*~
19+
# Various IDEs
20+
.project
21+
.idea/
22+
*.tmproj
23+
.vscode/

charts/upstream/Chart.yaml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
apiVersion: v2
2+
name: code-server
3+
description: A Helm chart for cdr/code-server
4+
5+
# A chart can be either an 'application' or a 'library' chart.
6+
#
7+
# Application charts are a collection of templates that can be packaged into versioned archives
8+
# to be deployed.
9+
#
10+
# Library charts provide useful utilities or functions for the chart developer. They're included as
11+
# a dependency of application charts to inject those utilities and functions into the rendering
12+
# pipeline. Library charts do not define any templates and therefore cannot be deployed.
13+
type: application
14+
15+
# This is the chart version. This version number should be incremented each time you make changes
16+
# to the chart and its templates, including the app version.
17+
# Versions are expected to follow Semantic Versioning (https://semver.org/)
18+
version: 1.0.3
19+
20+
# This is the version number of the application being deployed. This version number should be
21+
# incremented each time you make changes to the application. Versions are not expected to
22+
# follow Semantic Versioning. They should reflect the version the application is using.
23+
appVersion: 3.10.2

charts/upstream/README.md

Lines changed: 162 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,162 @@
1+
# code-server
2+
3+
![Version: 1.0.0](https://img.shields.io/badge/Version-1.0.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 3.10.2](https://img.shields.io/badge/AppVersion-3.10.2-informational?style=flat-square)
4+
5+
[code-server](https://github.com/cdr/code-server) code-server is VS Code running
6+
on a remote server, accessible through the browser.
7+
8+
This chart is community maintained by [@Matthew-Beckett](https://github.com/Matthew-Beckett) and [@alexgorbatchev](https://github.com/alexgorbatchev)
9+
10+
## TL;DR;
11+
12+
```console
13+
$ git clone https://github.com/cdr/code-server
14+
$ cd code-server
15+
$ helm upgrade --install code-server ci/helm-chart
16+
```
17+
18+
## Introduction
19+
20+
This chart bootstraps a code-server deployment on a
21+
[Kubernetes](http://kubernetes.io) cluster using the [Helm](https://helm.sh)
22+
package manager.
23+
24+
## Prerequisites
25+
26+
- Kubernetes 1.6+
27+
28+
## Installing the Chart
29+
30+
To install the chart with the release name `code-server`:
31+
32+
```console
33+
$ git clone https://github.com/cdr/code-server
34+
$ cd code-server
35+
$ helm upgrade --install code-server ci/helm-chart
36+
```
37+
38+
The command deploys code-server on the Kubernetes cluster in the default
39+
configuration. The [configuration](#configuration) section lists the parameters
40+
that can be configured during installation.
41+
42+
> **Tip**: List all releases using `helm list`
43+
44+
## Uninstalling the Chart
45+
46+
To uninstall/delete the `code-server` deployment:
47+
48+
```console
49+
$ helm delete code-server
50+
```
51+
52+
The command removes all the Kubernetes components associated with the chart and
53+
deletes the release.
54+
55+
## Configuration
56+
57+
The following table lists the configurable parameters of the code-server chart
58+
and their default values.
59+
60+
## Values
61+
62+
| Key | Type | Default | Description |
63+
|-----|------|---------|-------------|
64+
| affinity | object | `{}` | |
65+
| extraArgs | list | `[]` | |
66+
| extraConfigmapMounts | list | `[]` | |
67+
| extraContainers | string | `""` | |
68+
| extraInitContainers | string | `""` | |
69+
| extraSecretMounts | list | `[]` | |
70+
| extraVars | list | `[]` | |
71+
| extraVolumeMounts | list | `[]` | |
72+
| fullnameOverride | string | `""` | |
73+
| hostnameOverride | string | `""` | |
74+
| image.pullPolicy | string | `"Always"` | |
75+
| image.repository | string | `"codercom/code-server"` | |
76+
| image.tag | string | `"3.10.2"` | |
77+
| imagePullSecrets | list | `[]` | |
78+
| ingress.enabled | bool | `false` | |
79+
| nameOverride | string | `""` | |
80+
| nodeSelector | object | `{}` | |
81+
| persistence.accessMode | string | `"ReadWriteOnce"` | |
82+
| persistence.annotations | object | `{}` | |
83+
| persistence.enabled | bool | `true` | |
84+
| persistence.size | string | `"1Gi"` | |
85+
| podAnnotations | object | `{}` | |
86+
| podSecurityContext | object | `{}` | |
87+
| replicaCount | int | `1` | |
88+
| resources | object | `{}` | |
89+
| securityContext.enabled | bool | `true` | |
90+
| securityContext.fsGroup | int | `1000` | |
91+
| securityContext.runAsUser | int | `1000` | |
92+
| service.port | int | `8443` | |
93+
| service.type | string | `"ClusterIP"` | |
94+
| serviceAccount.create | bool | `true` | |
95+
| serviceAccount.name | string | `nil` | |
96+
| tolerations | list | `[]` | |
97+
| volumePermissions.enabled | bool | `true` | |
98+
| volumePermissions.securityContext.runAsUser | int | `0` | |
99+
100+
Specify each parameter using the `--set key=value[,key=value]` argument to `helm
101+
install`. For example,
102+
103+
```console
104+
$ helm upgrade --install code-server \
105+
ci/helm-chart \
106+
--set persistence.enabled=false
107+
```
108+
109+
The above command sets the the persistence storage to false.
110+
111+
Alternatively, a YAML file that specifies the values for the above parameters
112+
can be provided while installing the chart. For example,
113+
114+
```console
115+
$ helm upgrade --install code-server ci/helm-chart -f values.yaml
116+
```
117+
118+
> **Tip**: You can use the default [values.yaml](values.yaml)
119+
120+
# Extra Containers
121+
122+
There are two parameters which allow to add more containers to pod.
123+
Use `extraContainers` to add regular containers
124+
and `extraInitContainers` to add init containers. You can read more
125+
about init containers in [k8s documentation](https://kubernetes.io/docs/concepts/workloads/pods/init-containers/).
126+
127+
Both parameters accept strings and use them as a templates
128+
129+
Example of using `extraInitContainers`:
130+
131+
``` yaml
132+
extraInitContainers: |
133+
- name: customization
134+
image: {{ .Values.image.repository }}:{{ .Values.image.tag }}
135+
imagePullPolicy: IfNotPresent
136+
env:
137+
- name: SERVICE_URL
138+
value: https://open-vsx.org/vscode/gallery
139+
- name: ITEM_URL
140+
value: https://open-vsx.org/vscode/item
141+
command:
142+
- sh
143+
- -c
144+
- |
145+
code-server --install-extension ms-python.python
146+
code-server --install-extension golang.Go
147+
volumeMounts:
148+
- name: data
149+
mountPath: /home/coder
150+
151+
```
152+
153+
With this yaml in file `init.yaml`, you can execute
154+
155+
```console
156+
$ helm upgrade --install code-server \
157+
ci/helm-chart \
158+
--values init.yaml
159+
```
160+
161+
to deploy code-server with python and golang extensions preinstalled
162+
before main container have started.
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
1. Get the application URL by running these commands:
2+
{{- if .Values.ingress.enabled }}
3+
{{- range $host := .Values.ingress.hosts }}
4+
{{- range .paths }}
5+
http{{ if $.Values.ingress.tls }}s{{ end }}://{{ $host.host }}{{ . }}
6+
{{- end }}
7+
{{- end }}
8+
{{- else if contains "NodePort" .Values.service.type }}
9+
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "code-server.fullname" . }})
10+
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
11+
echo http://$NODE_IP:$NODE_PORT
12+
{{- else if contains "LoadBalancer" .Values.service.type }}
13+
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
14+
You can watch the status of by running 'kubectl get --namespace {{ .Release.Namespace }} svc -w {{ include "code-server.fullname" . }}'
15+
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "code-server.fullname" . }} -o jsonpath='{.status.loadBalancer.ingress[0].ip}')
16+
echo http://$SERVICE_IP:{{ .Values.service.port }}
17+
{{- else if contains "ClusterIP" .Values.service.type }}
18+
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include "code-server.name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
19+
echo "Visit http://127.0.0.1:8080 to use your application"
20+
kubectl port-forward $POD_NAME 8080:80
21+
{{- end }}
22+
23+
Administrator credentials:
24+
25+
Password: echo $(kubectl get secret --namespace {{ .Release.Namespace }} {{ template "code-server.fullname" . }} -o jsonpath="{.data.password}" | base64 --decode)
Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
{{/* vim: set filetype=mustache: */}}
2+
{{/*
3+
Expand the name of the chart.
4+
*/}}
5+
{{- define "code-server.name" -}}
6+
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
7+
{{- end -}}
8+
9+
{{/*
10+
Create a default fully qualified app name.
11+
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
12+
If release name contains chart name it will be used as a full name.
13+
*/}}
14+
{{- define "code-server.fullname" -}}
15+
{{- if .Values.fullnameOverride -}}
16+
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" -}}
17+
{{- else -}}
18+
{{- $name := default .Chart.Name .Values.nameOverride -}}
19+
{{- if contains $name .Release.Name -}}
20+
{{- .Release.Name | trunc 63 | trimSuffix "-" -}}
21+
{{- else -}}
22+
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
23+
{{- end -}}
24+
{{- end -}}
25+
{{- end -}}
26+
27+
{{/*
28+
Create chart name and version as used by the chart label.
29+
*/}}
30+
{{- define "code-server.chart" -}}
31+
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
32+
{{- end -}}
33+
34+
{{/*
35+
Common labels
36+
*/}}
37+
{{- define "code-server.labels" -}}
38+
helm.sh/chart: {{ include "code-server.chart" . }}
39+
{{ include "code-server.selectorLabels" . }}
40+
{{- if .Chart.AppVersion }}
41+
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
42+
{{- end }}
43+
app.kubernetes.io/managed-by: {{ .Release.Service }}
44+
{{- end }}
45+
46+
{{/*
47+
Selector labels
48+
*/}}
49+
{{- define "code-server.selectorLabels" -}}
50+
app.kubernetes.io/name: {{ include "code-server.name" . }}
51+
app.kubernetes.io/instance: {{ .Release.Name }}
52+
{{- end }}
53+
54+
{{/*
55+
Create the name of the service account to use
56+
*/}}
57+
{{- define "code-server.serviceAccountName" -}}
58+
{{- if .Values.serviceAccount.create -}}
59+
{{ default (include "code-server.fullname" .) .Values.serviceAccount.name }}
60+
{{- else -}}
61+
{{ default "default" .Values.serviceAccount.name }}
62+
{{- end -}}
63+
{{- end -}}

0 commit comments

Comments
 (0)