A Cookiecutter template to scaffold Helm + Kustomize Kubernetes deployments with per-environment overlays.
Project description
cookiecutter-kubernetes-deployment
A Cookiecutter template that scaffolds
a Kubernetes deployment combining a Helm upstream chart with Kustomize
base + per-environment overlays. A post-generation hook resolves the chart
version and renders its values.yaml automatically.
Features
- Helm + Kustomize — a vendored upstream Helm chart wrapped in a Kustomize
basewithdevelopment/productionoverlays. - Dynamic chart details — the post-gen hook pulls the latest chart version and values so the deployment starts up to date.
- Generated governance — the rendered project ships its own README, CONTRIBUTING, CODE_OF_CONDUCT and a license of your choice (MIT / GPL / Proprietary).
Requirements
- Python 3.12+
- Helm and
helm-docs on your
PATH— the post-generation hook calls them (with network access to the chart repo).
Usage
Generate a deployment straight from GitHub:
uvx cookiecutter gh:goabonga/cookiecutter-kubernetes-deployment
# or: cookiecutter gh:goabonga/cookiecutter-kubernetes-deployment
Or install the published template from PyPI and bake the bundled copy:
pip install cookiecutter-kubernetes-deployment
cookiecutter "$(python -c 'import cookiecutter_kubernetes_deployment as p; print(p.__path__[0])')"
You'll be prompted for the chart name, namespace, repository, alias,
author_name and license. The generated tree:
<name>/
├── base/kustomization.yaml
├── overlays/
│ ├── development/{kustomization,secret-generator}.yaml
│ └── production/{kustomization,secret-generator}.yaml
├── resources/kustomization.yaml
├── upstream/ # Helm chart (Chart.yaml, values.yaml, …)
├── upstream.sh
└── README.md / CONTRIBUTING.md / CODE_OF_CONDUCT.md / LICENSE
Deploy with Kustomize:
kubectl apply -k overlays/development
kubectl apply -k overlays/production
Development
git clone https://github.com/goabonga/cookiecutter-kubernetes-deployment.git
cd cookiecutter-kubernetes-deployment
uv sync
uv run pytest # bakes the template (needs Helm + helm-docs + network)
uvx cookiecutter . # generate a project from the working copy
See CONTRIBUTING.md for the workflow, the commit-message convention and the release process. By participating you agree to the Code of Conduct. Security issues: see SECURITY.md.
License
Distributed under the MIT License.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters