manyfold
by tina.junold
Manyfold is a self-hosted digital asset manager for 3D print files, organising models, their files and metadata into browsable libraries.
About this chart
manyfold
Manyfold is a self-hosted digital asset manager for 3D print files, organising models, their files and metadata into browsable libraries.
Homepage: https://gitlab.com/ideaplexus/charts
Maintainers
| Name | Url | |
|---|---|---|
| Tina Junold | [email protected] | https://ideaplexus.com |
Source Code
- https://gitlab.com/ideaplexus/charts/-/tree/main/charts/manyfold
- https://github.com/manyfold3d/manyfold
Requirements
Kubernetes: >=1.29.0-0
| Repository | Name | Version |
|---|---|---|
| https://charts.ideaplexus.com | common | 1.1.0 |
Editions
Manyfold ships two images, and edition picks between them.
solo (default) | standard | |
|---|---|---|
| Redis | built into the container | external, redis.url is required |
| Database | SQLite on the config volume | PostgreSQL or MySQL/MariaDB |
| Needs anything else in the cluster | no | yes |
| Suitable for | a single user, a first look | more than one user, upstream's recommendation |
The chart refuses to render a combination that cannot work: the standard
edition without redis.url or with the sqlite3 adapter, a server adapter
without database.host, or both a password and an existingSecret.
solo
Installs as it is. Everything lives on the config volume, so keep
persistence.enabled:
persistence:
enabled: true
size: 2Gi
standard
Point it at a Redis and a database you run yourself; this chart deploys neither. Both hosts are evaluated as templates, so they can reference a release installed alongside it:
edition: standard
redis:
url: "redis://{{ .Release.Name }}-redis-master:6379/1"
database:
adapter: postgresql
host: "{{ .Release.Name }}-postgresql"
port: 5432
name: manyfold
username: manyfold
password: change-me
With credentials you manage elsewhere, name the secrets instead. The chart then creates none of its own:
existingSecret: manyfold-app-secrets
existingSecretKeyBaseKey: secret-key-base
database:
existingSecret: manyfold-db-credentials
existingSecretPasswordKey: db-password
Libraries
A library is a directory of model files. Manyfold does not discover them, so a library is two things: the directory has to be mounted into the container, and it has to be registered in Manyfold.
Each entry needs a name and a mountPath, plus one source.
libraries:
- name: models
mountPath: /models
create: true
existingClaim: manyfold-models
- name: archive
mountPath: /archive
readOnly: true
nfs:
server: nas.example.com
path: /export/3d
- name: local
mountPath: /local
hostPath: /srv/models
An entry without a source gets an emptyDir, which is only useful for a smoke
test.
Registering a library
create: true registers that entry on start, so the library is there the first
time you open the UI. Without it, the entry is only mounted and you enter its
mountPath in Manyfold's "new library" form yourself.
An init container does the work, and it runs per entry:
- the library is created, or
- it already exists and is left alone, so a restart changes nothing, or
- Manyfold rejects the path and the init container fails, which keeps the pod from starting rather than leaving you with a half-configured instance.
It runs as puid/pgid, not as root, because that is the user Manyfold checks
the path against. Running it as root would accept a directory the application
itself cannot use.
Read-only libraries
readOnly: true mounts the volume read-only, which is the natural thing to
reach for with an NFS export you do not want written to. Manyfold does not
support it: it requires a library path to be writable and refuses to register
one that is not, whether through create or through the form. An entry that
sets both create and readOnly is rejected while rendering.
So readOnly is only useful for a directory you mount for some other reason.
For an actual library, mount it writable.
Secret key base
Rails signs sessions and cookies with SECRET_KEY_BASE. The chart generates one
on first install and looks it up on upgrade, so it stays stable; changing it
logs everyone out. Set secretKeyBase to supply your own, or existingSecret
to keep it out of your values entirely.
Uploads through an Ingress
Model files are large. An ingress controller's default body size limit will reject them, so raise it:
ingress:
enabled: true
hostname: manyfold.example.com
annotations:
nginx.ingress.kubernetes.io/proxy-body-size: 2048m
Replicas
replicaCount defaults to 1 and the update strategy to Recreate, so two pods
never hold the same ReadWriteOnce volume during a rollout. The solo edition
cannot be scaled at all: each pod would run its own Redis and its own work
queue. More than one replica needs the standard edition, an external Redis and
a database, and shared storage for the libraries.
Values
| Key | Type | Default | Description |
|---|---|---|---|
| affinity | object | {} | Affinity rules for the pod |
| args | list | [] | Arguments for the command |
| command | list | [] | Command to run instead of the image entrypoint |
| commonAnnotations | object | {} | Annotations added to every resource |
| commonLabels | object | {} | Labels added to every resource |
| containerPorts.http | int | 3214 | HTTP port the application listens on |
| containerSecurityContext.allowPrivilegeEscalation | bool | false | Disallow privilege escalation |
| containerSecurityContext.capabilities | object | {"drop":["ALL"]} | Linux capabilities |
| containerSecurityContext.enabled | bool | false | Enable the container security context. Off by default: the image runs an s6 supervisor that drops to puid/pgid itself and writes to paths outside the config volume. |
| containerSecurityContext.readOnlyRootFilesystem | bool | false | Mount the root filesystem read-only |
| containerSecurityContext.runAsNonRoot | bool | true | Run as a non-root user |
| containerSecurityContext.runAsUser | int | 1000 | User id to run as |
| containerSecurityContext.seccompProfile | object | {"type":"RuntimeDefault"} | Seccomp profile |
| customLivenessProbe | object | {} | A complete probe replacing the built-in liveness probe. Only used when livenessProbe.enabled is false. |
| customReadinessProbe | object | {} | A complete probe replacing the built-in readiness probe. Only used when readinessProbe.enabled is false. |
| customStartupProbe | object | {} | A complete probe replacing the built-in startup probe. Only used when startupProbe.enabled is false. |
| database.adapter | string | "sqlite3" | Database adapter. Use mysql2 for MariaDB. sqlite3 only makes sense with the solo edition. |
| database.existingSecret | string | "" | Name of an existing secret holding the database password. Evaluated as a template. |
| database.existingSecretPasswordKey | string | "password" | Key inside that secret |
| database.host | string | "" | Database host. Evaluated as a template. Required unless the adapter is sqlite3. |
| database.name | string | "/config/manyfold.sqlite3" | Database name. With sqlite3 this is the path of the database file, which has to be on the config volume. |
| database.password | string | "" | Database password, stored in a secret this chart creates. Mutually exclusive with database.existingSecret. |
| database.port | string | "" | Database port. Left out when empty, so the adapter default applies. |
| database.username | string | "manyfold" | Database user |
| edition | string | "solo" | Manyfold edition, solo or standard. It selects the image and decides what else has to be configured. |
| existingSecret | string | "" | Name of an existing secret holding the secret key base, instead of letting the chart manage one. Evaluated as a template. |
| existingSecretKeyBaseKey | string | "secret-key-base" | Key inside that secret |
| extraDeploy | list | [] | Extra objects to deploy with the release, rendered as templates |
| extraEnvVars | list | [] | Extra environment variables |
| extraEnvVarsCM | list | [] | ConfigMaps to take environment variables from |
| extraEnvVarsSecret | list | [] | Secrets to take environment variables from |
| extraVolumeMounts | list | [] | Extra volume mounts for the container |
| extraVolumes | list | [] | Extra volumes for the pod |
| fullnameOverride | string | "" | Override the fully generated object names |
| global.defaultStorageClass | string | "" | Global default StorageClass for Persistent Volume(s) |
| global.imagePullSecrets | list | [] | Global Docker registry secret names |
| global.imageRegistry | string | "" | Global Docker image registry |
| image.digest | string | "" | Image digest in the form sha256:aa.... Overrides the tag when set. |
| image.pullPolicy | string | "IfNotPresent" | Image pull policy |
| image.pullSecrets | list | [] | Image pull secrets, as - name: my-secret |
| image.registry | string | "docker.io" | Image registry |
| image.repository | string | "" | Image repository. Empty derives it from edition: manyfold3d/manyfold-solo or manyfold3d/manyfold. Set it for a mirror or a fork. |
| image.tag | string | "" | Image tag. Defaults to the chart appVersion. |
| ingress.annotations | object | {} | Annotations for the Ingress. Uploading large model files needs a matching body size limit here. |
| ingress.apiVersion | string | "" | API version, detected when empty |
| ingress.enabled | bool | false | Create an Ingress |
| ingress.extraHosts | list | [] | Extra hosts |
| ingress.extraPaths | list | [] | Extra paths on the main host |
| ingress.extraRules | list | [] | Extra rules |
| ingress.extraTls | list | [] | Extra TLS blocks |
| ingress.hostname | string | "manyfold.local" | Hostname |
| ingress.ingressClassName | string | "" | Ingress class name |
| ingress.path | string | "/" | Path |
| ingress.pathType | string | "ImplementationSpecific" | Path type |
| ingress.secrets | list | [] | TLS secrets to create, each with name, key and certificate |
| ingress.selfSigned | bool | false | Use a self-signed certificate |
| ingress.tls | bool | false | Add a TLS block for the hostname, for cert-manager or a self-signed certificate |
| libraries | list | [] | Model libraries to mount. Each entry needs a name and a mountPath, plus one source: existingClaim, hostPath or nfs. Without a source an emptyDir is used, which is only useful for a smoke test. The mountPath is what you enter in Manyfold's new library form, unless the entry sets create. |
| livenessProbe.enabled | bool | true | Enable the built-in liveness probe |
| livenessProbe.failureThreshold | int | 6 | Consecutive failures tolerated |
| livenessProbe.initialDelaySeconds | int | 0 | Seconds before the first check. Can stay at 0 while the startup probe is enabled. |
| livenessProbe.periodSeconds | int | 10 | Seconds between checks |
| livenessProbe.successThreshold | int | 1 | Consecutive successes needed after a failure |
| livenessProbe.timeoutSeconds | int | 5 | Seconds after which a check times out |
| multiuser | bool | false | Enable multiuser mode, which adds accounts and per-user permissions instead of an open instance |
| nameOverride | string | "" | Override the chart name used to construct object names |
| namespaceOverride | string | "" | Override the namespace the objects are created in |
| nodeSelector | object | {} | Node labels the pod is scheduled on |
| persistence.accessMode | string | "ReadWriteOnce" | Access mode |
| persistence.annotations | object | {} | Annotations for the claim |
| persistence.enabled | bool | true | Use a PersistentVolumeClaim. Without it the config volume is an emptyDir and its contents are lost on restart. |
| persistence.existingClaim | string | "" | Use an existing claim instead of creating one. Evaluated as a template. |
| persistence.mountPath | string | "/config" | Mount path of the config volume |
| persistence.selector | object | {} | Selector for the claim |
| persistence.size | string | "1Gi" | Size of the claim |
| persistence.storageClass | string | "" | StorageClass. Empty uses the cluster default. |
| pgid | int | 1000 | Group id the application runs as |
| pluginsPath | string | "/config/plugins" | Path plugins are loaded from. Keep it on the config volume so they survive a restart. |
| podAnnotations | object | {} | Annotations for the pods |
| podLabels | object | {} | Labels for the pods |
| podSecurityContext.enabled | bool | true | Enable the pod security context |
| podSecurityContext.fsGroup | int | 1000 | Group that owns the mounted volumes. Match it to pgid. |
| podSecurityContext.fsGroupChangePolicy | string | "OnRootMismatch" | When to apply fsGroup ownership |
| priorityClassName | string | "" | Priority class for the pod |
| puid | int | 1000 | User id the application runs as, and the owner of files it writes |
| readinessProbe.enabled | bool | true | Enable the built-in readiness probe |
| readinessProbe.failureThreshold | int | 6 | Consecutive failures tolerated |
| readinessProbe.initialDelaySeconds | int | 0 | Seconds before the first check |
| readinessProbe.periodSeconds | int | 10 | Seconds between checks |
| readinessProbe.successThreshold | int | 1 | Consecutive successes needed after a failure |
| readinessProbe.timeoutSeconds | int | 5 | Seconds after which a check times out |
| redis.url | string | "" | Redis connection URL, f |
Deploy manyfold with OpenTenant
Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has manyfold 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 chartmanyfold is pinned at v0.5.4 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