qbittorrent
by alekc
BitTorrent client with an optional Gluetun or built-in WireGuard VPN sidecar and a Prometheus metrics exporter
About this chart
qbittorrent
BitTorrent client with an optional Gluetun or built-in WireGuard VPN sidecar and a Prometheus metrics exporter
qBittorrent is an open-source BitTorrent client. This chart wraps the hotio qBittorrent image, and can route its traffic through a Gluetun or built-in WireGuard VPN sidecar, with an optional Prometheus metrics exporter and alert rule.
Quick start
helm repo add alekc https://charts.alekc.dev
helm repo update
helm install my-qbittorrent alekc/qbittorrent \
--set persistence.enabled=true \
--set ingress.enabled=true
Or directly from the OCI registry, no helm repo add needed:
helm install my-qbittorrent oci://charts.alekc.dev/qbittorrent --version 2.8.0
Verifying the signature
curl -sO https://charts.alekc.dev/pubring.gpg
helm pull oci://charts.alekc.dev/qbittorrent --version 2.8.0 --verify --keyring pubring.gpg
A minimal working values.yaml:
persistence:
enabled: true
size: 5Gi
ingress:
enabled: true
hosts:
- host: qbittorrent.example.com
paths:
- path: /
pathType: ImplementationSpecific
Maintainers
| Name | Url | |
|---|---|---|
| alekc | [email protected] |
Source Code
- https://github.com/qbittorrent/qBittorrent
- https://github.com/hotio/qbittorrent
- https://gitlab.com/alexander-chernov/helm/qbittorrent
Values
| Key | Type | Default | Description |
|---|---|---|---|
| additionalManifests | object | {} | Additional raw Kubernetes manifests to render alongside the chart's own resources. Supports any valid Kubernetes object; values are templated with tpl, so a manifest can reference .Release.Namespace and friends. |
| affinity | object | {} | |
| annotations.deployment | object | {} | Deployment's annotations |
| autoscaling.enabled | bool | false | |
| autoscaling.maxReplicas | int | 100 | |
| autoscaling.minReplicas | int | 1 | |
| autoscaling.targetCPUUtilizationPercentage | int | 80 | |
| btService.annotations | object | {} | Annotations to add to the BitTorrent Service |
| btService.externalIps | list | [] | |
| btService.port | int | 6881 | |
| btService.type | string | "ClusterIP" | |
| clearStaleLocks.enabled | bool | true | |
| clearStaleLocks.image | string | "busybox:1.38" | |
| clearStaleLocks.imagePullPolicy | string | "IfNotPresent" | |
| commonAnnotations | object | {} | Annotations merged onto every resource this chart renders, in addition to each resource's own dedicated annotations field. |
| commonLabels | object | {} | Labels merged onto every resource this chart renders. Never reaches selector/matchLabels, safe to change without forcing a Deployment recreate. |
| deployment.revisionHistoryLimit | int | 1 | Number of replicaset revisions |
| deployment.strategy | object | {"type":"Recreate"} | Rollout strategy type |
| env.PGID | string | "1000" | |
| env.PUID | string | "1000" | |
| env.TZ | string | "Europe/London" | |
| extraContainers | list | [] | Extra sidecar containers appended to the pod spec, templated with tpl so they can reference .Release.Namespace and friends. |
| extraInitContainers | list | [] | |
| fullnameOverride | string | "" | |
| image.pullPolicy | string | "IfNotPresent" | |
| image.repository | string | "ghcr.io/hotio/qbittorrent" | |
| image.tag | string | "" | |
| imagePullSecrets | list | [] | |
| ingress.annotations | object | {} | |
| ingress.className | string | "" | |
| ingress.enabled | bool | false | |
| ingress.hosts[0].host | string | "chart-example.local" | |
| ingress.hosts[0].paths[0].path | string | "/" | |
| ingress.hosts[0].paths[0].pathType | string | "ImplementationSpecific" | |
| ingress.tls | list | [] | |
| livenessProbe | object | {"enabled":true,"failureThreshold":6,"httpGet":{"path":"/","port":"http"},"initialDelaySeconds":30,"periodSeconds":10} | Pod liveness probe. The hotio image runs a full s6-overlay init (PUID/PGID remapping, config bootstrap) before the WebUI binds to :8080, which routinely takes longer than Kubernetes' own probe defaults; initialDelaySeconds/failureThreshold below are set generously for that, not for a typical fast-starting app. Set enabled: false to disable outright rather than overriding the block to {}/null, Helm's deep merge would leave these defaults in place either way. |
| metrics.enabled | bool | false | |
| metrics.exporter.env.existingSecret | object | unset, password is used | Read the WebUI password from an existing Secret instead of password |
| metrics.exporter.env.existingSecret.key | string | "password" | Key in the Secret holding the password |
| metrics.exporter.env.existingSecret.name | string | "" | Secret name; when set, password is ignored |
| metrics.exporter.env.logLevel | string | "INFO" | |
| metrics.exporter.env.password | string | "adminadmin" | |
| metrics.exporter.env.port | int | 9022 | |
| metrics.exporter.env.user | string | "admin" | |
| metrics.exporter.image.pullPolicy | string | "IfNotPresent" | |
| metrics.exporter.image.repository | string | "esanchezm/prometheus-qbittorrent-exporter" | |
| metrics.exporter.image.tag | string | "v1.8.0" | |
| metrics.prometheusRule.annotations | object | {} | Annotations to add to the PrometheusRule |
| metrics.prometheusRule.enabled | bool | false | |
| metrics.prometheusRule.labels | object | {} | |
| metrics.prometheusRule.rules | list | [] | |
| metrics.serviceMonitor.annotations | object | {} | Annotations to add to the ServiceMonitor |
| metrics.serviceMonitor.enabled | bool | false | |
| metrics.serviceMonitor.interval | string | "15s" | |
| metrics.serviceMonitor.labels | object | {} | |
| metrics.serviceMonitor.scrapeTimeout | string | "5s" | |
| nameOverride | string | "" | |
| networkPolicy.annotations | object | {} | Annotations to add to the NetworkPolicy |
| networkPolicy.enabled | bool | false | Render a NetworkPolicy restricting ingress to the WebUI and BitTorrent ports, and egress to DNS plus a broad allowance. qBittorrent connects to arbitrary peers/trackers across the internet, so egress is broad by default, see Gotchas. |
| networkPolicy.extraEgress | list | [] | Additional raw egress rules, appended as-is under spec.egress. |
| networkPolicy.extraIngress | list | [] | Additional raw ingress rules, appended as-is under spec.ingress. |
| nodeSelector | object | {} | |
| persistence.accessMode | string | "ReadWriteOnce" | |
| persistence.additionalMounts | list | [] | |
| persistence.additionalVolumes | list | [] | |
| persistence.annotations | object | {} | Annotations to add to the PersistentVolumeClaim |
| persistence.enabled | bool | true | |
| persistence.existingClaim | string | "" | |
| persistence.size | string | "800Mi" | |
| persistence.storageClass | string | "" | |
| podAnnotations | object | {} | |
| podSecurityContext | object | {} | |
| readinessProbe | object | {"enabled":true,"failureThreshold":6,"httpGet":{"path":"/","port":"http"},"initialDelaySeconds":30,"periodSeconds":10} | Pod readiness probe. Same startup-time reasoning as livenessProbe. |
| replicaCount | int | 1 | |
| resources | object | {} | |
| securityContext | object | {} | |
| serviceAccount.annotations | object | {} | |
| serviceAccount.create | bool | true | Specifies whether a service account should be created |
| serviceAccount.name | string | "" | |
| tolerations | list | [] | |
| vpn.builtIn.additionalPorts | string | "" | |
| vpn.builtIn.config | string | "x" | If the config is not empty, it will be copied into /config/wireguard/wg0.conf with an init container config: |
| vpn.builtIn.interface | string | "wg0" | |
| vpn.builtIn.lanNetwork | string | "" | |
| vpn.builtIn.privoxy.annotations | object | {} | Annotations to add to the privoxy Service |
| vpn.builtIn.privoxy.enabled | bool | false | |
| vpn.builtIn.privoxy.externalIps | list | [] | |
| vpn.builtIn.privoxy.type | string | "ClusterIP" | |
| vpn.enabled | bool | false | |
| vpn.gluetun.env.DNS_KEEP_NAMESERVER | string | "on" | |
| vpn.gluetun.env.TZ | string | "Europe/London" | |
| vpn.gluetun.env.VPN_TYPE | string | "wireguard" | |
| vpn.gluetun.image.pullPolicy | string | "IfNotPresent" | |
| vpn.gluetun.image.repository | string | "ghcr.io/qdm12/gluetun" | |
| vpn.gluetun.image.tag | string | "v3.41.3" | |
| vpn.gluetun.securityContext.capabilities.add[0] | string | "NET_ADMIN" | |
| vpn.type | string | "builtIn" | |
| webService.annotations | object | {} | Annotations to add to the WebUI Service |
| webService.externalIps | list | [] | |
| webService.port | int | 80 | |
| webService.type | string | "ClusterIP" |
Gotchas
vpn.enabledisfalseby default: traffic goes out directly, unproxied. Setvpn.typetogluetun(a full sidecar container, configured entirely throughvpn.gluetun.env, see Gluetun's own docs) orbuiltIn(uses the hotio image's own WireGuard client, configured viavpn.builtIn.config) before routing real traffic through this chart.vpn.gluetun.envvalues containing secrets (WireGuard keys, VPN provider credentials) render as plain container env vars. PreferadditionalManifestswith an ExternalSecret and avalueFrom.secretKeyRefentry (any non-string value undervpn.gluetun.envrenders as avalueFromblock) over inlining real key material invalues.yamlorhelmValues.clearStaleLocks.enabledonly takes effect whendeployment.strategy.typeisRecreate. qBittorrent v4+ leaves an ipc-socket/lockfile on the PVC if a pod dies ungracefully; the next pod treats itself as a duplicate instance and exits 0 in a restart loop with the WebUI never binding. The init container clears both before start, but only underRecreate, sinceRollingUpdatecan briefly run two pods against the same volume and deleting a live instance's lockfile out from under it is unsafe.networkPolicy.enabledallows broad egress to0.0.0.0/0by default. qBittorrent connects to arbitrary BitTorrent peers and trackers across the internet, which isn't a small fixed CIDR. Narrow it withnetworkPolicy.extraEgressonly if you're routing all traffic through a VPN sidecar with its own egress control.metrics.exporter.env.passwordis the qBittorrent WebUI's own admin password, required so the exporter can authenticate and scrape/api/v2stats; it isn't a separate credential. To keep it out of your values, setmetrics.exporter.env.existingSecret.name(and.key, defaultpassword) to a Secret you manage;passwordis then ignored.
Upgrade notes
No breaking changes yet. This section will list migration steps for any future release with
a kind: removed or kind: changed entry in artifacthub.io/changes that requires one.
Deploy qbittorrent with OpenTenant
Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has qbittorrent 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 chartqbittorrent is pinned at v2.11.1 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