|
| 1 | +# code-server |
| 2 | + |
| 3 | +[code-server](https://github.com/cdr/code-server) code-server is VS Code running on a remote server, accessible through the browser. |
| 4 | + |
| 5 | +## TL;DR; |
| 6 | + |
| 7 | +```console |
| 8 | +$ git clone https://github.com/cdr/code-server.git |
| 9 | +$ helm install deployment/chart |
| 10 | +``` |
| 11 | + |
| 12 | +## Introduction |
| 13 | + |
| 14 | +This chart bootstraps a code-server deployment on a [Kubernetes](http://kubernetes.io) cluster using the [Helm](https://helm.sh) package manager. |
| 15 | + |
| 16 | +## Prerequisites |
| 17 | + |
| 18 | + - Kubernetes 1.6+ |
| 19 | + |
| 20 | +## Installing the Chart |
| 21 | + |
| 22 | +To install the chart with the release name `my-release`: |
| 23 | + |
| 24 | +```console |
| 25 | +$ helm install --name my-release deployment/chart |
| 26 | +``` |
| 27 | + |
| 28 | +The command deploys code-server on the Kubernetes cluster in the default configuration. The [configuration](#configuration) section lists the parameters that can be configured during installation. |
| 29 | + |
| 30 | +> **Tip**: List all releases using `helm list` |
| 31 | +
|
| 32 | +## Uninstalling the Chart |
| 33 | + |
| 34 | +To uninstall/delete the `my-release` deployment: |
| 35 | + |
| 36 | +```console |
| 37 | +$ helm delete my-release |
| 38 | +``` |
| 39 | + |
| 40 | +The command removes all the Kubernetes components associated with the chart and deletes the release. |
| 41 | + |
| 42 | +## Configuration |
| 43 | + |
| 44 | +The following table lists the configurable parameters of the nginx-ingress chart and their default values. |
| 45 | + |
| 46 | + |
| 47 | +The following table lists the configurable parameters of the code-server chart and their default values. |
| 48 | + |
| 49 | +| Parameter | Description | Default | |
| 50 | +| --------------------------------- | ------------------------------------------ | --------------------------------------------------------- | |
| 51 | +| `image.registry` | Code-server image registry | `docker.io` | |
| 52 | +| `image.repository` | Code-server Image name | `codercom/code-server` | |
| 53 | +| `image.tag` | Code-server Image tag | `{TAG_NAME}` | |
| 54 | +| `image.pullPolicy` | Code-server image pull policy | `IfNotPresent` | |
| 55 | +| `nameOverride` | String to partially override code-server.fullname template with a string (will prepend the release name) | `nil` | |
| 56 | +| `fullnameOverride` | String to fully override code-server.fullname template with a string | |
| 57 | +| `hostnameOverride` | String to fully override code-server container hostname | |
| 58 | +| `service.type` | Kubernetes Service type | `NodePort` | |
| 59 | +| `service.port` | Service HTTP port | `8443` | |
| 60 | +| `ingress.enabled` | Enable ingress controller resource | `false` | |
| 61 | +| `ingress.hosts[0].name` | Hostname to your code-server installation | `code-server.local` | |
| 62 | +| `ingress.hosts[0].path` | Path within the url structure | `/` | |
| 63 | +| `ingress.hosts[0].tls` | Utilize TLS backend in ingress | `false` | |
| 64 | +| `ingress.hosts[0].certManager` | Add annotations for cert-manager | `false` | |
| 65 | +| `ingress.hosts[0].tlsSecret` | TLS Secret (certificates) | `code-server.local-tls-secret` | |
| 66 | +| `ingress.hosts[0].annotations` | Annotations for this host's ingress record | `[]` | |
| 67 | +| `ingress.secrets[0].name` | TLS Secret Name | `nil` | |
| 68 | +| `ingress.secrets[0].certificate` | TLS Secret Certificate | `nil` | |
| 69 | +| `ingress.secrets[0].key` | TLS Secret Key | `nil` | |
| 70 | +| `resources` | CPU/Memory resource requests/limits | Memory: `512Mi`, CPU: `300m` | |
| 71 | +| `persistence.enabled` | Enable persistence using PVC | `true` | |
| 72 | +| `persistence.storageClass` | PVC Storage Class for code-server volume | `nil` (uses alpha storage class annotation) | |
| 73 | +| `persistence.accessMode` | PVC Access Mode for code-server volume | `ReadWriteOnce` | |
| 74 | +| `persistence.size` | PVC Storage Request for code-server volume | `8Gi` |
| 75 | + |
| 76 | +Specify each parameter using the `--set key=value[,key=value]` argument to `helm install`. For example, |
| 77 | + |
| 78 | +```console |
| 79 | +$ helm install --name my-release \ |
| 80 | + --set persistence.enabled=false \ |
| 81 | + deployment/chart |
| 82 | +``` |
| 83 | + |
| 84 | +The above command sets the the persistence storage to false. |
| 85 | + |
| 86 | +Alternatively, a YAML file that specifies the values for the above parameters can be provided while installing the chart. For example, |
| 87 | + |
| 88 | +```console |
| 89 | +$ helm install --name my-release -f values.yaml deployment/chart |
| 90 | +``` |
| 91 | + |
| 92 | +> **Tip**: You can use the default [values.yaml](values.yaml) |
| 93 | +
|
| 94 | +## Image |
| 95 | + |
| 96 | +The `image` parameter allows specifying which image will be pulled for the chart. |
0 commit comments