openproject
by OpenProject
A Helm chart for running OpenProject via Kubernetes
About this chart
Helm chart for OpenProject
This is the chart for OpenProject itself. It bootstraps an OpenProject instance, optionally with a PostgreSQL database and Memcached.
Prerequisites
- Kubernetes 1.16+
- Helm 3.0.0+
- PV provisioner support in the underlying infrastructure
Helm chart Provenance and Integrity
We sign our chart using the Helm Provenance and Integrity functionality. You can find the used public key here
- https://github.com/opf/helm-charts/blob/main/signing.key
- https://keys.openpgp.org/vks/v1/by-fingerprint/CB1CA0488A75B7471EA1B087CF56DD6A0AE260E5
We recommend using the Helm GnuPG plugin. With it you can manually verify the signature like this:
helm repo add openproject https://charts.openproject.org
helm fetch --prov openproject/openproject
helm gpg verify openproject-*.tgz
Installation
Demo video
Below is a demo video on how to install OpenProject using the helm chart, including configuration for Let's Encrypt TLS certificate with cert-manager and ingress-nginx:
Accompanying README instructions for the demo video: opf/helm-charts/demo
Quick start
Add the OpenProject Helm repository:
helm repo add openproject https://charts.openproject.org
helm repo update
Install the OpenProject chart in a dedicated openproject namespace:
helm upgrade --create-namespace --namespace openproject --install openproject openproject/openproject
The namespace is optional, but we highly recommend it as it does make it easier to manage the resources created for OpenProject.
Bundled Memcached
The chart runs one Memcached instance using the Docker Official Image memcached:1.6.45-alpine.
It runs as UID/GID 11211 with a read-only root filesystem. UDP is disabled, and the Service is internal.
No custom image is built or published.
The official image tracks upstream releases and base-image updates. The chart pins a version; review image updates regularly.
Upgrading from Bitnami
A normal Helm upgrade replaces the old cache with a new Deployment and internal Service.
The chart updates the application's cache address automatically. Cache contents are discarded; no dump or PVC migration is needed.
Database records and attachments remain in their existing storage. Expect a cold cache and a brief cache interruption during the upgrade.
The new Deployment uses Recreate so updates do not send requests to two independent caches.
Review your values and remove obsolete Bitnami options. Do not use --reuse-values for this transition.
| Previous setting | New setting or action |
|---|---|
memcached.bundled, memcached.connection.* | Retained. External cache connections are unchanged. |
memcached.image.* | Set registry, repository, tag, and optional sha256 (without the prefix). Use the official image. |
memcached.resources, resourcesPreset | Retained; leave container memory headroom above memcached.memoryLimit for connections and server overhead. |
memcached.arguments, extraFlags | Set memcached.memoryLimit and extraArgs; review native Memcached flags. |
memcached.nodeSelector, affinity, tolerations, topologySpreadConstraints | Retained. |
memcached.livenessProbe, readinessProbe | memcached.probes.liveness, probes.readiness, merged with global probe settings. |
memcached.auth, architecture, replicaCount, persistence, metrics, volumePermissions, global | Removed. Use an external cache for authentication or a separately managed topology. |
An enabled legacy memcached.auth.enabled is rejected instead of silently removing SASL authentication.
For an external cache, set memcached.bundled: false and provide memcached.connection.host and port.
Use application configuration for any external cache credentials.
If you manage NetworkPolicies separately, allow application pods to reach the new Service on TCP 11211.
The chart's NetworkPolicies include this rule. The new resource name ends in -cache; update external monitoring that references old names.
Keep the previous chart package and values if rollback is needed. Reinstalling them starts another empty cache; there is no cache data to recover.
Configuration
Configuration of the chart takes place through defined values, and a catch-all entry environment to provide all possible variables through ENV that OpenProject supports. To get more information about the possible values, please see our guide on environment variables.
Available OpenProject specific helm values
We try to map the most common options to chart values directly for ease of use. The most common ones are listed here, feel free to extend available values through a pull request.
OpenProject image and version
By default, the helm chart will target the latest stable major release. You can define a custom supported docker tag using image.tag. Override container registry and repository using image.registry and image.repository, respectively.
Please make sure to use the -slim variant of OpenProject, as the all-in-one container is adding unnecessary services and will not work as expected with default options such as operating as a non-root user.
SECRET_KEY_BASE
The SECRET_KEY_BASE in rails applications is used to sign or encrypt data such as cookies, sessions or tokens.
The chart automatically generates a value for this if you don't provide one.
You can provide one via an existing secret, however.
openproject:
secretKeyBase:
existingSecret: my-secret-key-base-secret
secretKey: secret-key-base
Helm-charts version 13.5.4 and higher of the helm chart will automatically create a kubernetes secret using a random string.
If you have not passed a environment.SECRET_KEY_BASE value previously, we recommend updating to the newest helm version to have it auto-generate.
If you have an existing strong secret, you are safe already and nothing needs to be done. You can optionally place it as the existingSecret as shown in the Helm chart documentation to use the conventional secret to pass it into the specs.
HTTPS mode
Regardless of the TLS mode of ingress, OpenProject needs to be told whether it's expected to run and return HTTPS responses (or generate correct links in mails, background jobs, etc.). This will likely be true, even if OpenProject is not responsible for terminating TLS connections inside the deployment. It will cause OpenProject to output secure cookies, as well as other protection measures.
[!CAUTION] If you're not terminating https anywhere in your stack, then set
openproject.https=false. This is not recommended for production systems
Seed locale
By default, demo data and global names for types, statuses, etc. will be in English. If you wish to set a custom locale, set openproject.seed_locale=XX, where XX can be a two-character ISO code. For currently supported values, see the OPENPROJECT_AVAILABLE__LANGUAGES default value in the environment guide.
Admin user
By default, OpenProject generates an admin user with password admin which is required to change after first interactive login.
If you're operating an automated deployment with fresh databases for testing, this default approach might not be desirable.
You can customize the password as well as name, email, and whether a password change is enforced on first login with these variables:
openproject.admin_user.password="my-secure-password"
openproject.admin_user.password_reset="false"
openproject.admin_user.name="Firstname Lastname"
openproject.admin_user.mail="[email protected]"
TMP volume mounts
OpenProject needs some tmp volumes to be mounted in /app/tmp and /tmp, if containerSecurityContext.readOnlyRootFilesystem is set to true.
This is due to the application server storing a non-configurable PID file and some temporary caches or files being put there.
This setting is true by default (to be precise, it follows its configured value or falls back to containerSecurityContext.readOnlyRootFilesystem).
To explicitly disable this, use openproject.useTmpVolumes=false. This will fail if readOnlyRootFilesystem is true.
These volumes do not contain any critical information and can be excluded from backups using the labels/annotations values.
Kubernetes Pod Security Standards
With the default values, the rendered chart is compatible with the Kubernetes Pod Security Standards restricted profile. This includes the OpenProject web, worker, cron, seeder, hocuspocus, and Helm test pods, including their init containers.
Pod Security Admission enforcement is configured by the cluster operator on the namespace, not by the chart. For example:
pod-security.kubernetes.io/enforce: restricted
pod-security.kubernetes.io/enforce-version: latest
The bundled PostgreSQL subchart and Memcached Deployment also render with restricted-compatible security contexts at the pinned chart versions. If you enable Bitnami's PostgreSQL volumePermissions init container, that pod may fail restricted enforcement because it runs as root. The bundled RustFS Deployment (see rustfs.bundled) uses this chart's own restricted-compatible security context too.
ReadWriteMany volumes
By default and when using filesystem-based attachments, OpenProject requires the Kubernetes cluster to support ReadWriteMany (rwx) volumes. This is due to the fact that multiple container instances need access to write to the attachment storage.
To avoid using ReadWriteMany, you will need to configure an S3 compatible object storage instead which is shown in the advanced configuration guide.
persistence:
enabled: false
s3:
enabled: true
accessKeyId:
# host:
# port:
Updating the configuration
The OpenProject configuration can be changed through environment variables.
You can use helm upgrade to set individual values.
For instance:
helm upgrade --reuse-values --namespace openproject my-openproject --set environment.OPENPROJECT_IMPRESSUM__LINK=https://www.openproject.org/legal/imprint/ --set environment.OPENPROJECT_APP__TITLE='My OpenProject'
Find out more about the configuration through environment variables section.
Uninstalling the Chart
To uninstall the release with the name my-openproject do the following:
helm uninstall --namespace openproject my-openproject
Note: This will not remove the persistent volumes created while installing. The easiest way to ensure all PVCs are deleted as well is to delete the openproject namespace (
kubectl delete namespace openproject). If you installed OpenProject into the default namespace, you can delete the volumes manually one by one.
Troubleshooting
Web deployment stuck in CrashLoopBackoff
Describing the pod may yield an error like the following:
65s) kubelet Error: failed to start container "openproject": Error response from daemon: failed to create shim task: OCI runtime create failed: runc create failed: unable to start container process: error during container init: error setting cgroup config for procHooks process: failed to write "400000": write /sys/fs/cgroup/cpu,cpuacct/kubepods/burstable/pod990fa25e-dbf0-4fb7-9b31-9d7106473813/openproject/cpu.cfs_quota_us: invalid argument: unknown
This can happen when using minikube. By default, it initialises the cluster with 2 CPUs only.
Either increase the cluster's resources to have at least 4 CPUs or install the OpenProject helm chart with a reduced CPU limit by adding the following option to the install command:
--set resources.limits.cpu=2
Development
Please refer to DEVELOPMENT.md for local development.
TLS
Create a TLS certificate, e.g. using mkcert.
mkcert helm-example.openproject-dev.com
Create the tls secret in kubernetes.
kubectl -n openproject create secret tls openproject-tls \
--key="helm-example.openproject-dev.com-key.pem" \
--cert="helm-example.openproject-dev.com.pem"
Set the tls secret value during installation or an upgrade by adding the following.
--set ingress.tls.enabled=true --set tls.secretName=openproject-tls
Root CA
If you want to add your own root CA for outgoing TLS connection, do the following.
- Put the certificate into a config map.
kubectl -n openproject-dev create configmap ca-pemstore --from-file=/path/to/rootCA.pem
To make OpenProject use this CA for outgoing TLS connection, set the following options.
--set egress.tls.rootCA.configMap=ca-pemstore \
--set egress.tls.rootCA.fileName=rootCA.pem
Distrust a root CA
If a root CA in the image must not be trusted before a fixed image is available, replace the trust store with your own CA bundle. The example below removes the roots of the compromised eMudhra intermediates (see https://emudhra.we-have-a-problem.com/).
- Create a CA bundle without these roots. If you use your own root CA, append it to the bundle.
Deploy openproject with OpenTenant
Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has openproject on a Hetzner server. Change the host, add apps from the marketplace, then copy the generated files. Providers and prices are samples, and nothing here is sent anywhere.
- Pick a serverConnect Hetzner, OVHcloud or AWS. The builder starts on Hetzner, the cheapest sample rate.
- Place the chartopenproject is pinned at v14.0.0 in opentenant.yaml. Drag more apps from the marketplace onto a rack.
- ApplySave opentenant.yaml and main.tf from the console, then run the commands below.
# opentenant.yaml, main.tf and dns.tf come from the builder below opentenant validate opentenant.yaml terraform init && terraform apply