Skip to content

Commit

Permalink
v0.13.0
Browse files Browse the repository at this point in the history
  • Loading branch information
DaemonDude23 committed Feb 4, 2023
1 parent c984a9e commit 4c1539d
Show file tree
Hide file tree
Showing 31 changed files with 466 additions and 254 deletions.
23 changes: 13 additions & 10 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,24 +29,27 @@ repos:
- id: requirements-txt-fixer
- id: check-ast
repo: 'https://github.com/pre-commit/pre-commit-hooks'
rev: v4.3.0
rev: v4.4.0
- repo: https://github.com/asottile/reorder_python_imports
rev: v3.8.2
rev: v3.9.0
hooks:
- id: reorder-python-imports
args: [--application-directories, '.:src', --py36-plus]
- hooks:
- id: black
language_version: python3.9
language_version: python3.10
args:
- --line-length
- "140"
repo: https://github.com/psf/black
rev: 22.6.0
- repo: https://gitlab.com/pycqa/flake8
rev: 3.9.2
rev: 23.1.0
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v0.991
hooks:
- id: flake8
args:
- --max-line-length
- "140"
- id: mypy
args:
- --check-untyped-defs
- --ignore-missing-imports
- --install-types
- --non-interactive
files: src/helmizer.py
12 changes: 12 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,18 @@
"request": "launch",
"type": "python"
},
{
"args": [
"--debug",
"./examples/sortOptions/helmizer.yaml"
],
"console": "integratedTerminal",
"cwd": "${workspaceFolder}",
"name": "Example - sortOptions",
"program": "${workspaceFolder}/src/helmizer.py",
"request": "launch",
"type": "python"
},
{
"args": [
"--debug",
Expand Down
28 changes: 25 additions & 3 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
# Changelog
**Changelog**

- [Changelog](#changelog)
- [2023](#2023)
- [v0.13.0](#v0130)
- [2022](#2022)
- [v0.12.0](#v0120)
- [v0.11.0](#v0110)
- [v0.10.0](#v0100)
- [2021](#2021)
- [v0.9.1](#v091)
- [v0.9.0](#v090)
- [v0.8.0](#v080)
Expand All @@ -17,17 +20,34 @@

---

# 2023

## [v0.13.0](https://github.com/DaemonDude23/helmizer/releases/tag/v0.13.0)

February 4 2023

**Enhancements**

- Improved type checking thanks to `mypy`.
- Fixed missing support for `sortOptions` and added an example.

**Housekeeping**

- Updated pre-commit dependencies and added `mypy`.

# 2022

## [v0.12.0](https://github.com/DaemonDude23/helmizer/releases/tag/v0.12.0)

July 27 2022

**Bugfixes**

- Fixed missing support for `secretGenerator` despite having something in [`secretGenerator` examples](./examples/secretGenerator/).
- Don't crash if `helmizer.version` and/or `helmizer.sort-keys` are not defined in the `helmizer.yaml` config... or practically anything. Omit the `helmizer` section of the config if you wish.

**Enhancements**

- Fixed missing support for `secretGenerator` despite having something in [`secretGenerator` examples](./examples/secretGenerator/).
- Added `--no-sort-keys` CLI flag to disable key sorting of _all_ keys output kustomization.yaml on the CLI.

**Housekeeping**
Expand Down Expand Up @@ -66,6 +86,8 @@ January 21 2022
- `pre-commit` updates.
- Tweaked `requirements`.

# 2021

## [v0.9.1](https://github.com/DaemonDude23/helmizer/releases/tag/v0.9.1)

November 11 2021
Expand Down
9 changes: 6 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ kustomize:
namespace: ""
nameSuffix: []
openapi: {}
patches: []
patchesJson6902: []
patchesStrategicMerge: []
replacements: []
Expand Down Expand Up @@ -144,6 +145,7 @@ kustomize: # this is essentially an overlay for your eventual kustomization.yam
namespace: ""
nameSuffix: []
openapi: {}
patches: []
patchesJson6902: []
patchesStrategicMerge: []
replacements: []
Expand All @@ -160,7 +162,7 @@ kustomize: # this is essentially an overlay for your eventual kustomization.yam
For local installation/use of the raw script, I use a local virtual environment to isolate dependencies:

```bash
git clone https://github.com/DaemonDude23/helmizer.git -b v0.12.0
git clone https://github.com/DaemonDude23/helmizer.git -b v0.13.0
cd helmizer
```

Expand Down Expand Up @@ -193,7 +195,7 @@ pip3 install -U virtualenv==20.16.2
```
3. Setup relative virtual environment:
```bash
virtualenv --python=python3.9 ./venv/
virtualenv --python=python3.10 ./venv/
```
4. _Activate_ this virtual environment for pip3:
```bash
Expand Down Expand Up @@ -275,6 +277,7 @@ The `sealed-secrets` **Helm** chart is used for examples for its small scope. He
- [namespace](examples/namespace/)
- [nameSuffix](examples/nameSuffix/)
- [openapi](examples/openapi/)
- [patches](examples/patches/)
- [patchesJson6902](examples/patchesJson6902/)
- [patchStrategicMerge](examples/patchesStrategicMerge/)
- [replacements](examples/replacements/)
Expand Down Expand Up @@ -378,4 +381,4 @@ resources:

- [Kustomize Docs](https://kubectl.docs.kubernetes.io/references/kustomize/)

All `kustomize` configuration options are supported. See [here](https://kubectl.docs.kubernetes.io/references/kustomize/kustomization/) for reference.
All `kustomize` configuration options which are not deprecated by `kustomize` are supported. See [here](https://kubectl.docs.kubernetes.io/references/kustomize/kustomization/) for reference.
19 changes: 9 additions & 10 deletions examples/commonAnnotations/README.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
# commonAnnotations
**commonAnnotations**

- [commonAnnotations](#commonannotations)
- [Generating the Helm Template](#generating-the-helm-template)
- [Generate Kustomization](#generate-kustomization)
- [Raw Python](#raw-python)
- [Validate](#validate)
- [Generating the Helm Template](#generating-the-helm-template)
- [Generate Kustomization](#generate-kustomization)
- [Raw Python](#raw-python)
- [Validate](#validate)

---

## Generating the Helm Template
# Generating the Helm Template

```bash
helm -n sealed-secrets template \
Expand All @@ -20,17 +19,17 @@ helm -n sealed-secrets template \
stable/sealed-secrets
```

## Generate Kustomization
# Generate Kustomization

_These assumes you're in the root directory of this repository_

### Raw Python
## Raw Python

```bash
python3 ./src/helmizer.py ./examples/commonAnnotations/helmizer.yaml
```

## Validate
# Validate

```bash
kubectl kustomize .
Expand Down
8 changes: 4 additions & 4 deletions examples/commonAnnotations/kustomization.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@ commonAnnotations:
kind: Kustomization
namespace: sealed-secrets
resources:
- sealed-secrets/templates/cluster-role.yaml
- sealed-secrets/templates/cluster-role-binding.yaml
- sealed-secrets/templates/service.yaml
- sealed-secrets/templates/cluster-role.yaml
- sealed-secrets/templates/deployment.yaml
- sealed-secrets/templates/role-binding.yaml
- sealed-secrets/templates/role.yaml
- sealed-secrets/templates/sealedsecret-crd.yaml
- sealed-secrets/templates/service-account.yaml
- sealed-secrets/templates/role.yaml
- sealed-secrets/templates/role-binding.yaml
- sealed-secrets/templates/service.yaml
23 changes: 12 additions & 11 deletions examples/commonLabels/README.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
# commonLabels
**commonLabels**

- [commonLabels](#commonlabels)
- [Generating the Helm Template](#generating-the-helm-template)
- [Generate Kustomization](#generate-kustomization)
- [Raw Python](#raw-python)
- [Validate](#validate)
- [Generating the Helm Template](#generating-the-helm-template)
- [Generate Kustomization](#generate-kustomization)
- [Raw Python](#raw-python)
- [Validate](#validate)

---

## Generating the Helm Template
[https://kubectl.docs.kubernetes.io/references/kustomize/kustomization/commonlabels/](https://kubectl.docs.kubernetes.io/references/kustomize/kustomization/commonlabels/)

# Generating the Helm Template

```bash
helm -n sealed-secrets template \
Expand All @@ -20,18 +21,18 @@ helm -n sealed-secrets template \
stable/sealed-secrets
```

## Generate Kustomization
# Generate Kustomization

_These assumes you're in the root directory of this repository_

### Raw Python
## Raw Python

```bash
python3 ./src/helmizer.py ./examples/commonLabels/helmizer.yaml
```

## Validate
# Validate

```bash
kubectl kustomize .
kubectl kustomize ./examples/commonLabels/
```
6 changes: 0 additions & 6 deletions examples/commonLabels/helmizer.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,6 @@ helmizer:
- --version
- '1.12.2'
- stable/sealed-secrets
dry-run: false
kustomization-directory: .
kustomization-file-name: kustomization.yaml
resource-absolute-paths: false
sort-keys: true
version: '0.1.0'
kustomize:
namespace: sealed-secrets
resources:
Expand Down
23 changes: 12 additions & 11 deletions examples/configMapGenerator/README.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
# configMapGenerator
**configMapGenerator**

- [configMapGenerator](#configmapgenerator)
- [Generating the Helm Template](#generating-the-helm-template)
- [Generate Kustomization](#generate-kustomization)
- [Local Python](#local-python)
- [Validate](#validate)
- [Generating the Helm Template](#generating-the-helm-template)
- [Generate Kustomization](#generate-kustomization)
- [Local Python](#local-python)
- [Validate](#validate)

---

## Generating the Helm Template
[https://kubectl.docs.kubernetes.io/references/kustomize/kustomization/configmapgenerator/](https://kubectl.docs.kubernetes.io/references/kustomize/kustomization/configmapgenerator/)

# Generating the Helm Template

```bash
helm -n sealed-secrets template \
Expand All @@ -20,18 +21,18 @@ helm -n sealed-secrets template \
stable/sealed-secrets
```

## Generate Kustomization
# Generate Kustomization

_These assumes you're in the root directory of this repository_

### Local Python
## Local Python

```bash
python3 ./src/helmizer.py ./examples/configMapGenerator/helmizer.yaml
```

## Validate
# Validate

```bash
kubectl kustomize .
kubectl kustomize ./examples/configMapGenerator/
```
1 change: 1 addition & 0 deletions examples/crds/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
TODO
23 changes: 12 additions & 11 deletions examples/generatorOptions/README.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
# generatorOptions
**generatorOptions**

- [generatorOptions](#generatoroptions)
- [Generating the Helm Template](#generating-the-helm-template)
- [Generate Kustomization](#generate-kustomization)
- [Local Python](#local-python)
- [Validate](#validate)
- [Generating the Helm Template](#generating-the-helm-template)
- [Generate Kustomization](#generate-kustomization)
- [Local Python](#local-python)
- [Validate](#validate)

---

## Generating the Helm Template
https://kubectl.docs.kubernetes.io/references/kustomize/kustomization/generatoroptions/

# Generating the Helm Template

```bash
helm -n sealed-secrets template \
Expand All @@ -20,18 +21,18 @@ helm -n sealed-secrets template \
stable/sealed-secrets
```

## Generate Kustomization
# Generate Kustomization

_These assumes you're in the root directory of this repository_

### Local Python
## Local Python

```bash
python3 ./src/helmizer.py ./examples/generatorOptions/helmizer.yaml
```

## Validate
# Validate

```bash
kubectl kustomize .
kubectl kustomize ./examples/generatorOptions/
```

0 comments on commit 4c1539d

Please sign in to comment.