Skip to main content

Deploy to Kubernetes Cluster

caution

Procedure outlined here is only applicable for upgrading to latest version

Use this procedure if you are deploying OneDev into Kubernetes. Below procedure assumes that you've added OneDev chart repository via below command:

helm repo add onedev https://code.onedev.io/onedev/~helm

If you want to upgrade the chart version together with image version:

helm repo update onedev 
helm upgrade onedev onedev/onedev -n onedev --reuse-values

If you only want to upgrade the image version:

helm upgrade onedev onedev/onedev -n onedev --set image.tag=<OneDev version> --reuse-values
note

--reuse-values reuses values of the previous release, which means settings newly added to the chart keep their previous state instead of taking new chart defaults. This is safe for existing installations, but when you want to enable a feature added by a newer chart, pass its settings explicitly via --set, or use --reset-then-reuse-values to have new chart defaults applied on top of your previous settings

Upgrade to 16.4.0

Git access via SSH is now disabled by default in the Helm chart. If your existing installation exposes SSH through a LoadBalancer, nginx ingress controller, or another TCP proxy, retain SSH access by enabling it explicitly during upgrade:

helm upgrade onedev onedev/onedev -n onedev --set ssh.enabled=true --reuse-values

Without this setting, the chart removes the SSH port from OneDev's Kubernetes Service. HTTP access and Git over HTTP are not affected.

SSH Service settings have also moved under the new ssh section:

  1. Move service.ports.ssh to ssh.port.
  2. Move service.separateSSH.enabled to ssh.separateService.enabled.
  3. Move the remaining service.separateSSH settings to ssh.separateService, except service.separateSSH.port, which is replaced by the shared ssh.port.