Helm chart for deploying kiwix-serve with automated ZIM file downloads.
- π Automated ZIM file downloads with retry logic and checksum verification
- π One-time or periodic download modes (Job or CronJob)
- π¦ OCI-based Helm chart distribution via GHCR
- π‘οΈ Built on the bjw-s Common library
- πΎ Persistent storage with configurable size and storage class
- π― Keep-all file management strategy for archival use cases
- π Automated dependency updates with Renovate
- Kubernetes 1.19+
- Helm 3.8+
- Persistent Volume provisioner (for PVC support)
# Login to GHCR (if repository is private)
helm registry login ghcr.io -u <username>
# Install chart
helm install my-kiwix oci://ghcr.io/jacaudi/charts/kiwix \
--version v0.1.0 \
--namespace kiwix \
--create-namespace \
--values values.yaml# Clone repository
git clone https://github.com/jacaudi/kiwix-helm-chart.git
cd kiwix-helm-chart
# Update dependencies
helm dependency update
# Install
helm install my-kiwix . \
--namespace kiwix \
--create-namespace \
--values values.yamlSee docs/VALUES.md for complete values documentation.
# Minimal configuration
persistence:
size: 100Gi
ingress:
enabled: true
host: kiwix.localFor production deployments, see docs/VALUES.md for examples.
The chart uses a standalone downloader pattern with two controllers:
- Downloader Controller: Job (one-time) or CronJob (periodic) that downloads ZIM files to shared storage
- Main Controller: Deployment running kiwix-serve that serves the downloaded files
Both controllers share a PVC mounted at /data. The downloader reads URLs from a ConfigMap generated from zimFiles.
User provides zimFiles list
β
ConfigMap (zim-urls.json)
β
Downloader (Job/CronJob)
β
PVC (/data)
β
Kiwix-serve (Deployment)
ZIM files can be large (100MB - 100GB). The chart uses a keep-all strategy, accumulating files over time.
Recommended PVC sizes:
- Small demo (1-2 files): 10-50 Gi
- Medium archive (5-10 files): 100-200 Gi
- Large archive (20+ files): 500+ Gi
Monitor PVC usage over time, especially when using periodic updates.
This project uses Renovate to automatically keep dependencies up-to-date:
- GitHub Actions: Auto-updated to latest versions
- Docker base images: Tracks Alpine Linux releases
- Helm dependencies: Monitors bjw-s common library updates
- Container images: Tracks kiwix-serve and downloader versions
Schedule: Daily at 2am UTC
Auto-merge policy: Patch updates (1.0.x) automatically merge after 3 days if CI passes.
Dependency Dashboard: Check the Dependency Dashboard issue for pending updates.
Trigger Renovate manually via GitHub Actions:
gh workflow run renovate.yamlOr via GitHub UI: Actions β Renovate β Run workflow
This project uses Uplift to automate semantic versioning and releases.
All commits must follow Conventional Commits format:
<type>: <description>
[optional body]
[optional footer]
Types:
feat:- New feature (minor version bump)fix:- Bug fix (patch version bump)docs:- Documentation changeschore:- Maintenance tasksrefactor:- Code refactoringBREAKING CHANGE:in footer - Major version bump
Examples:
git commit -m "feat: add support for custom ZIM checksums"
git commit -m "fix: correct CronJob schedule parsing"
git commit -m "docs: update installation instructions"Releases are created manually via GitHub Actions:
- Navigate to Actions β CI/CD Pipeline
- Click Run workflow
- Select
mainbranch - Check Trigger Release option
- Click Run workflow
Uplift will:
- Analyze commits since last release
- Determine version bump (major/minor/patch)
- Update
Chart.yamlversion and appVersion - Generate/update
CHANGELOG.md - Create git tag (e.g.,
v0.2.0) - Create GitHub release with changelog
- Trigger Docker and Helm chart publishing
Quality gates: Tests and builds must pass before release job runs.
# For Job
kubectl logs -n kiwix job/my-kiwix-downloader
# For CronJob (get latest job)
kubectl logs -n kiwix $(kubectl get jobs -n kiwix -l app.kubernetes.io/name=kiwix -o name | tail -1)kubectl exec -n kiwix deployment/my-kiwix -- ls -lh /data# Port-forward
kubectl port-forward -n kiwix svc/my-kiwix 8080:8080
# Access in browser
open http://localhost:8080Download timeout: Increase Job timeout or check network connectivity
downloader:
resources:
limits:
cpu: 1000m
memory: 512MiPVC full: Increase size or manually delete old files
kubectl exec -n kiwix deployment/my-kiwix -- rm /data/old-file.zimcd image
docker build -t ghcr.io/jacaudi/kiwix-downloader:test .
docker push ghcr.io/jacaudi/kiwix-downloader:test# Lint
helm lint .
# Template
helm template test . --values values.yaml
# Dry-run install
helm install test . --dry-run --debugSee repository license.
Contributions welcome! Please open an issue or pull request.