Installing Gitea on K3s as a single node
Gitea with its own Postgres, SSH on 2222, and the Recreate strategy.
What it’s for
Section titled “What it’s for”A small single-node Gitea on K3s without the chart’s HA defaults.
What you need
Section titled “What you need”- K3s with Traefik and the local-path provisioner
- The
giteaHelm chart (12.7.0 tested)
- Values that matter:
strategy: type: Recreatepostgresql-ha: enabled: falsevalkey-cluster: enabled: falsepostgresql: enabled: trueservice: ssh: type: LoadBalancer port: 2222gitea: config: server: SSH_PORT: 2222 SSH_LISTEN_PORT: 2222 cache: ADAPTER: memory queue: TYPE: level- Install:
helm upgrade --install gitea gitea-charts/gitea -n gitea --create-namespace -f values.yaml- Register your SSH keys and switch remotes to port 2222 (see the SSH keys recipe).
Check it worked
Section titled “Check it worked”- Gitea and its Postgres pods Running. About 160 MiB total in this lab.
git pushoverssh://git@<host>:2222/...works.
Traps seen
Section titled “Traps seen”- The chart defaults to a 3-node Postgres HA and a 3-node Valkey cluster.
- With the on-disk LevelDB queue, RollingUpdate crash-loops:
unable to lock level db. Use Recreate. - Host sshd stays on 22; Gitea uses 2222 to avoid a clash.
- Right after the first push to an empty repo, the commits API can return 409 for about a second.
Where this came from
Section titled “Where this came from”- Gitea crash-looped during a rolling update (2026-10-18)
- Reviewing phases 1 to 3 (2026-10-20)