Skip to content

Installation on Kubernetes

Kubernetes is the supported way to run HoyoShip. HoyoShip is installed with the Helm chart oci://code.forgejo.org/forgejo-helm/forgejo, version 17.1.5, configured to run the HoyoShip image. The chart’s resource names and value keys (forgejo, gitea:) are fixed by the chart; the examples below use them as they are.

  • A Kubernetes cluster with a default or named storage class.
  • A PostgreSQL or MySQL database for HoyoShip, prepared as described in Database Preparation.
  • An Ingress controller or a Gateway API implementation to expose the web interface.
  • Pull credentials for docker.io/doricodynamics/hoyoship, from support@doricod.com.
  • Helm 3.8 or later, which can install charts from OCI registries.

Create the namespace and the three secrets the values below refer to:

Terminal window
kubectl create namespace hoyoship
# Registry credentials from Dorico Dynamics
kubectl -n hoyoship create secret docker-registry hoyoship-registry \
--docker-server=docker.io \
--docker-username='<username>' \
--docker-password='<access token>'
# The first administrator account
kubectl -n hoyoship create secret generic hoyoship-admin \
--from-literal=username='<admin user>' \
--from-literal=password='<admin password>'
# The [database] section of app.ini
kubectl -n hoyoship create secret generic hoyoship-db-config \
--from-file=database=database.ini

Each key of the hoyoship-db-config secret names an app.ini section, and its value holds that section’s settings. database.ini contains all the database options, for example:

DB_TYPE=postgres
HOST=postgres.example.internal:5432
NAME=hoyoshipdb
USER=hoyoship
PASSWD=<database password>
SSL_MODE=require

Save the following as values.yaml, replacing the version, digest, storage class and host names with your own:

global:
imagePullSecrets:
- hoyoship-registry
image:
registry: docker.io
repository: doricodynamics/hoyoship
tag: 'vX.Y.Z'
digest: 'sha256:<digest of vX.Y.Z>'
rootless: true
podSecurityContext:
fsGroup: 1000
containerSecurityContext:
allowPrivilegeEscalation: false
capabilities:
drop:
- ALL
seccompProfile:
type: RuntimeDefault
persistence:
enabled: true
size: 10Gi
storageClass: '<storage class>'
gitea:
admin:
existingSecret: hoyoship-admin
config:
APP_NAME: HoyoShip
server:
ROOT_URL: https://hoyoship.example.com/
DOMAIN: hoyoship.example.com
SSH_DOMAIN: hoyoship.example.com
additionalConfigSources:
- secret:
secretName: hoyoship-db-config

After docker login, look up a release’s digest with docker buildx imagetools inspect docker.io/doricodynamics/hoyoship:vX.Y.Z. Pinning the digest as well as the tag makes every environment run exactly the image you tested. Any other app.ini setting from the Configuration Cheat Sheet can be set under gitea.config, with the section name as the key.

Terminal window
helm install hoyoship oci://code.forgejo.org/forgejo-helm/forgejo \
--version 17.1.5 \
--namespace hoyoship \
--values values.yaml

With the release name hoyoship, the chart creates the deployment hoyoship-forgejo and the services hoyoship-forgejo-http (port 3000) and hoyoship-forgejo-ssh (port 22, forwarded to the image’s SSH server on 2222). Wait for the pod to become ready:

Terminal window
kubectl -n hoyoship rollout status deploy/hoyoship-forgejo

To manage the installation with a GitOps tool such as Argo CD instead, point an application at the same chart, version and values.

Route https://hoyoship.example.com/ to the hoyoship-forgejo-http service on port 3000 through your Ingress controller or Gateway API implementation. The chart can create the Ingress or HTTPRoute for you through its ingress and route values. Terminate TLS in front of HoyoShip and keep ROOT_URL equal to the public address.

To offer Git over SSH, expose the hoyoship-forgejo-ssh service in the way your cluster allows, for example with a LoadBalancer service. If clients reach it on a port other than 22, set gitea.config.server.SSH_PORT to that port so that clone URLs show it.

  • Sign in with the administrator account, then read our recommendations.
  • To upgrade, change image.tag and image.digest and run helm upgrade with the same values, as described in the upgrade guide.