harbor

by QuenchWorks

Helm chartv0.0.72App 2.15.5Apache-2.0Verified publisher

Cloud-native OCI registry with role-based access control, replication, vulnerability scanning, and image signing. This umbrella chart wires seven QuenchWorks Harbor component images (core, jobservice, registry, registryctl, portal, the optional Trivy scan adapter, and the metrics exporter) over the QuenchWorks PostgreSQL and Valkey charts, each a minimal, nonroot, CVE-gated image pinned by digest.

About this chart

Quenchworks Harbor

Hardened Harbor, a cloud-native OCI registry with RBAC, replication, vulnerability scanning and image signing, as a single umbrella chart that wires nine minimal, nonroot, CVE-gated component images (pinned by digest) over the Quenchworks PostgreSQL and Valkey charts. Every container runs as uid 1001 on a read-only root filesystem with all capabilities dropped; each writable path is an emptyDir (or a PVC for registry storage). The images are cosign-signed (keyless / Sigstore) and the chart pins each one by its signed digest, never a tag. There is no upstream "prepare" bootstrap container: the chart generates every credential itself and persists it across upgrades.

Components

ComponentRoleOptional
coreAPI, token service, /v2 docker-protocol proxyno
jobserviceasync jobs (GC, replication, scan, retention)no
registrydocker distribution (blob/manifest storage)no
registryctlGC / quota controller (2nd container w/ registry)no
portalweb UI (static SPA on nginx)no
proxyfront-door nginx: / -> portal, API paths -> coreno
trivy adaptervulnerability scanner (trivy.enabled)yes
metrics exporterPrometheus metrics (metrics.enabled)yes

A hardened busybox image supplies the wait-for-core initContainer (the Harbor images carry no HTTP client). Backing services: PostgreSQL (one database, registry; core auto-migrates the schema on boot) and Valkey (six logical redis DBs multiplexed: core, registry, jobservice, cache-layer, trivy-store, trivy-jobqueue). Both are bundled by default and can be swapped for external instances. The Harbor CLI and content-trust/notary signing are out of scope for this chart.

Install

helm install reg oci://ghcr.io/quenchworks/charts/harbor

Self-contained: bundles in-cluster PostgreSQL and Valkey with deterministic credentials, fronted by a Traefik Ingress on host harbor.local. Set the host and external URL to your own:

helm install reg oci://ghcr.io/quenchworks/charts/harbor \
  --set ingress.host=harbor.example.com \
  --set externalURL=https://harbor.example.com

Turn on the optional scanner and metrics exporter:

helm install reg oci://ghcr.io/quenchworks/charts/harbor \
  --set trivy.enabled=true --set metrics.enabled=true

Verify the image

Every component image is cosign-signed (keyless / Sigstore). Verify them all:

for img in harbor-core harbor-jobservice harbor-registry harbor-registryctl \
           harbor-portal harbor-trivy-adapter harbor-exporter nginx busybox; do
  cosign verify ghcr.io/quenchworks/images/$img \
    --certificate-identity-regexp 'https://github.com/quenchworks/.+' \
    --certificate-oidc-issuer https://token.actions.githubusercontent.com
done

The bundled PostgreSQL and Valkey images are verified the same way (repos ghcr.io/quenchworks/images/postgresql and .../valkey); they ship with their own Quenchworks charts.

Each image also ships an SPDX SBOM and SLSA build provenance as attestations. Verify them with the GitHub CLI, for example:

gh attestation verify oci://ghcr.io/quenchworks/images/harbor-core \
  --owner quenchworks

Values

Per-component images. Each .digest is the factory contract (CI rewrites it after every green, scanned, signed build); the schema rejects tag-only references.

KeyDefaultNotes
images.pullPolicyIfNotPresentShared by all components. Always, IfNotPresent, or Never.
images.core.{repository,digest}ghcr.io/quenchworks/images/harbor-coreAPI + token service.
images.jobservice.{repository,digest}.../harbor-jobserviceAsync job runner.
images.registry.{repository,digest}.../harbor-registryDocker distribution.
images.registryctl.{repository,digest}.../harbor-registryctlGC / quota controller.
images.portal.{repository,digest}.../harbor-portalWeb UI.
images.trivyAdapter.{repository,digest}.../harbor-trivy-adapterOptional scanner.
images.exporter.{repository,digest}.../harbor-exporterOptional metrics exporter.
images.proxy.{repository,digest}.../nginxFront-door proxy.
images.busybox.{repository,digest}.../busyboxwait-for-core initContainer.

Global.

KeyDefaultNotes
nameOverride""Override the chart name in resource names.
logLevelinfoShared by all components: debug, info, warning, error, fatal.
externalURL""URL clients use to reach Harbor. Defaults to http://<ingress.host> when ingress is on. Must match the host you docker login to.
auth.adminPassword""Pin the admin password. Generated once (24 chars) and preserved across upgrades when empty.

Component: proxy (front door).

KeyDefaultNotes
proxy.enabledtrueSingle nginx entry point.
proxy.replicaCount1
proxy.service.typeClusterIP
proxy.service.port80Maps to proxy container port 8080.
proxy.resources50m/64Mi -> 500m/256MiRequests -> limits.

Component: core.

KeyDefaultNotes
core.replicaCount1
core.service.typeClusterIP
core.service.port80
core.resources100m/256Mi -> 2/1GiRequests -> limits.
core.csrfTrustedOrigins[]Extra hosts trusted for the UI login CSRF check. Bare host or host:port, no scheme. The externalURL host is always trusted.

Component: jobservice.

KeyDefaultNotes
jobservice.replicaCount1
jobservice.maxJobWorkers10Concurrent job workers.
jobservice.service.typeClusterIP
jobservice.service.port8080
jobservice.resources100m/128Mi -> 1/512MiRequests -> limits.

Component: registry (with registryctl as a second container).

KeyDefaultNotes
registry.replicaCount1
registry.service.typeClusterIP
registry.service.port5000
registry.resources100m/128Mi -> 1/1GiRequests -> limits.
registry.registryctl.service.typeClusterIP
registry.registryctl.service.port8080
registry.registryctl.resources50m/64Mi -> 500m/256MiRequests -> limits.

Component: portal.

KeyDefaultNotes
portal.replicaCount1
portal.service.typeClusterIP
portal.service.port80
portal.resources50m/64Mi -> 500m/256MiRequests -> limits.

Component: trivy scan adapter (optional).

KeyDefaultNotes
trivy.enabledfalseRegister the adapter as core's default scanner.
trivy.debugModefalse
trivy.insecurefalseSkip TLS verification to the registry.
trivy.ignoreUnfixedfalseReport only fixable vulnerabilities.
trivy.skipUpdatefalseSkip the Trivy DB download.
trivy.offlineScanfalse
trivy.securityCheckvulnScan categories.
trivy.dbRepositoryghcr.io/aquasecurity/trivy-dbTrivy DB OCI source, pulled at runtime.
trivy.service.{type,port}ClusterIP / 8080
trivy.persistence.enabledfalseCache PVC (DB + reports); emptyDir when false.
trivy.persistence.size5Gi
trivy.persistence.storageClass""
trivy.persistence.accessModes["ReadWriteOnce"]
trivy.resources100m/256Mi -> 1/1GiRequests -> limits.

Component: metrics exporter (optional).

KeyDefaultNotes
metrics.enabledfalseDeploy the exporter; core/registry/jobservice expose their own /metrics too.
metrics.exporter.service.{type,port}ClusterIP / 8001
metrics.exporter.resources50m/64Mi -> 500m/256MiRequests -> limits.
metrics.core.{path,port}/metrics / 8001
metrics.registry.{path,port}/metrics / 8001
metrics.jobservice.{path,port}/metrics / 8001

Database (PostgreSQL).

KeyDefaultNotes
postgresql.enabledtrueBundle the in-cluster PostgreSQL subchart.
postgresql.auth.usernameharbor
postgresql.auth.passwordharbor
postgresql.auth.databaseregistryCore auto-migrates the schema on boot.
postgresql.primary.persistence.{enabled,size}true / 8Gi
externalDatabase.host""Used when postgresql.enabled=false.
externalDatabase.port5432
externalDatabase.userharbor
externalDatabase.password""Or set existingSecret.
externalDatabase.databaseregistryMust already exist.
externalDatabase.sslmodedisable
externalDatabase.existingSecret""
externalDatabase.existingSecretPasswordKeypassword

Cache (Valkey).

KeyDefaultNotes
valkey.enabledtrueBundle the in-cluster Valkey subchart.
valkey.auth.enabledtrue
valkey.auth.passwordharbor-valkey
valkey.primary.persistence.{enabled,size}true / 8Gi
externalCache.host""Used when valkey.enabled=false.
externalCache.port6379
externalCache.password""
externalCache.existingSecret""
externalCache.existingSecretPasswordKeyredis-password
redisDB.{core,registry,jobservice,cacheLayer,trivyStore,trivyJobQueue}0/1/2/3/4/5Logical DB indexes on the shared Valkey. Rarely changed.

Storage, ingress, and cluster knobs.

KeyDefaultNotes
persistence.enabledtrueRegistry storage PVC mounted at /storage. emptyDir when false.
persistence.size50Gi
persistence.storageClass""Default class if unset.
persistence.accessModes["ReadWriteOnce"]
ingress.enabledtrueTraefik Ingress in front of the proxy Service.
ingress.classNametraefik
ingress.hostharbor.localDerives externalURL when that is unset.
ingress.annotations{}
ingress.tls.enabledfalse
ingress.tls.secretName""
serviceAccount.createtrueToken automount is off.
serviceAccount.name""Use an existing ServiceAccount.
serviceAccount.annotations{}
rbac.createfalseMinimal Role/RoleBinding.
networkPolicy.enabledtrue
networkPolicy.allowExternaltrueAllow ingress to portal/core from outside the release namespace; backend components stay restricted.
podDisruptionBudget.enabledtrue
podDisruptionBudget.minAvailable1

Plus the shared quench-common knobs applied to every component: podLabels, podAnnotations, nodeSelector, affinity, tolerations, topologySpreadConstraints, priorityClassName, schedulerName, terminationGracePeriodSeconds, podSecurityContext, and containerSecurityContext (both merge over the hardened defaults, your keys win).

Architecture

The whole app is reachable through one Service, the proxy (an nginx front door, proxy.enabled, default true). It routes / to the portal (UI) and /api, /service, /v2, /c, /chartrepo to core. Its Service is named after the release (e.g. reg-harbor) and maps port 80 to proxy 8080. A Traefik Ingress (ingress.enabled, default true) sits in front of that Service; ingress.host derives externalURL when it is unset. With no ingress, externalURL defaults to the in-cluster proxy Service URL. When proxy.enabled=false the chart fronts core/portal directly (set ingress.enabled=false and an explicit externalURL).

The token service is the trust anchor. The chart generates an RSA keypair, gives the private key to core (it signs registry-auth bearer tokens) and core validates them at /service/token. This is separate from internal TLS, which is disabled for in-cluster plaintext traffic. externalURL (or the ingress host) must match the host you docker login to, or token-audience checks reject pulls and pushes.

core is the API, token service, and public face of the registry for /v2. registry holds the actual blobs and manifests, with registryctl as a second container for GC and quota. jobservice runs async work (GC, replication, scan, retention) and waits on core readiness through a busybox initContainer before booting. portal serves the static UI. All of them share one PostgreSQL database (registry, schema auto-migrated by core) and one Valkey, on which Harbor multiplexes six logical redis DBs by index (redisDB.*). Registry blob storage is a PVC mounted at /storage (persistence.enabled, default 50Gi); for ephemeral installs an emptyDir is used.

replicaCount stays at 1 per component: the bundled PostgreSQL/Valkey and the shared registry storage are single-writer, so HA is a future capability.

Configuration examples

Admin login. User is always admin; read the generated password:

kubectl get secret reg-harbor -o jsonpath='{.data.HARBOR_ADMIN_PASSWORD}' | base64 -d ; echo

docker login and push/pull (host must match externalURL):

docker login harbor.example.com           # admin + the password above
docker tag alpine harbor.example.com/library/alpine
docker push harbor.example.com/library/alpine
docker pull harbor.example.com/library/alp

Deploy harbor with OpenTenant

Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has harbor 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.

  1. Pick a serverConnect Hetzner, OVHcloud or AWS. The builder starts on Hetzner, the cheapest sample rate.
  2. Place the chartharbor is pinned at v0.0.72 in opentenant.yaml. Drag more apps from the marketplace onto a rack.
  3. 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