linkwarden

by 0hlov3

Helm chartv1.1.0App v2.17.0

Linkwarden is a self-hosted, open-source collaborative bookmark manager that preserves a snapshot of every saved page.

About this chart

Linkwarden Helm Chart

Deploy Linkwarden, a self-hosted collaborative bookmark manager that keeps a snapshot of every saved page, on Kubernetes.

Requirements

  • Kubernetes 1.19+
  • Helm 3.8+
  • An external PostgreSQL database

Installation

helm repo add schoenwald https://charts.schoenwald.aero
helm install linkwarden schoenwald/linkwarden \
  --set env.nextauth.url=https://linkwarden.example.com/api/v1/auth \
  --set env.nextauth.secret="$(openssl rand -base64 32)" \
  --set externalPostgresql.host=postgresql.example.svc.cluster.local \
  --set externalPostgresql.username=linkwarden \
  --set externalPostgresql.password=<password> \
  --set persistence.enabled=true

For production, keep the secrets in existing Kubernetes Secrets (env.nextauth.existingSecret and externalPostgresql.existingSecret) instead of passing them as values.

Parameters

image parameters

NameDescriptionValue
image.registryimage registryghcr.io
image.repositoryimage repositorylinkwarden/linkwarden
image.pullPolicyimage pull policyIfNotPresent

Linkwarden Environment Config

NameDescriptionValue
env.nextauth.urlDefines the NEXTAUTH_URL and specifies the base URL for NextAuth.js authentication endpoints.http://localhost:3000/api/v1/auth
env.nextauth.secretDefines the NEXTAUTH_SECRET and is used by NextAuth.js to encrypt session tokens and JWTs. Can be generated via openssl rand -base64 32""
env.nextauth.existingSecret.nameDefines the NEXTAUTH_SECRET kubernetes secret name where to get the secret.""
env.nextauth.existingSecret.keyDefines the NEXTAUTH_SECRET kubernetes secret key where to get the secret.""
extraEnvadditional environment variables to pass to the Linkwarden deployment[]

Persistence

NameDescriptionValue
persistence.enabledStore Linkwarden data (/data/data: archived pages, screenshots, PDFs) in a PersistentVolumeClaim. When false, an emptyDir is used and the data is lost whenever the pod restartsfalse
persistence.sizeSize of the PersistentVolumeClaim for Linkwarden data1Gi
persistence.accessModeAccess mode of the PersistentVolumeClaimReadWriteOnce
persistence.storageClassNameStorageClass of the PersistentVolumeClaim. If empty, the default StorageClass is used""

Database Configuration

NameDescriptionValue
externalPostgresql.enabledEnable external PostgreSQL as the database backend.true
externalPostgresql.hostHostname of the external PostgreSQL database.postgresql.postgresql.svc.cluster.local
externalPostgresql.portPort for the external PostgreSQL database, as a quoted string (e.g. "5432")5432
externalPostgresql.databaseName of the database to use. Must be URL-safe (see externalPostgresql.password)linkwarden
externalPostgresql.usernameUsername of the database to use. Must be URL-safe (see externalPostgresql.password)""
externalPostgresql.passwordPassword of the database to use. It is inserted into DATABASE_URL without URL encoding, so it must not contain @ : / # ? or %""
externalPostgresql.existingSecret.nameName of an existing Kubernetes secret containing database credentials.""
externalPostgresql.existingSecret.keys.hostKey for the host in the existing secret.""
externalPostgresql.existingSecret.keys.portKey for the port in the existing secret. The value must be the bare port number (no trailing newline)""
externalPostgresql.existingSecret.keys.databaseKey for the database name in the existing secret.""
externalPostgresql.existingSecret.keys.usernameKey for the username in the existing secret.""
externalPostgresql.existingSecret.keys.passwordKey for the password in the existing secret.""

Traffic Exposure Parameters

NameDescriptionValue
service.typeService typeClusterIP
service.portservice port80
ingress.enabledEnable Ingress for the Linkwarden web UIfalse
ingress.classNameIngressClass that will be used to implement the Ingress""
ingress.annotationsAdditional annotations for the Ingress resource. To enable certificate autogeneration, place here your cert-manager annotations.{}
ingress.tlsTLS configuration[]

General

NameDescriptionValue
imagePullSecretsGlobal registry secret names as an array[]
nameOverrideString to partially override common.names.fullname""
fullnameOverrideString to fully override common.names.fullname""
serviceAccount.createSpecifies whether a ServiceAccount should be createdtrue
serviceAccount.automountAutomount service account token for the server service accounttrue
serviceAccount.annotationsAdditional custom annotations for the ServiceAccount{}
serviceAccount.nameThe name of the ServiceAccount to use.""
podAnnotationsAnnotations for pods{}
podLabelsLabels for pods{}
podSecurityContextpodSecurityContext for pods{}
securityContextsecurityContext for pods{}
resourcesSet container requests and limits for different resources like CPU or memory (essential for production workloads){}

Deploy linkwarden with OpenTenant

Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has linkwarden 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 chartlinkwarden is pinned at v1.1.0 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