Skip to content

fix: work around Viper dropping nil-value keys#190

Merged
tonyandrewmeyer merged 3 commits into
canonical:mainfrom
tonyandrewmeyer:fix-load-empty-keys
May 19, 2026
Merged

fix: work around Viper dropping nil-value keys#190
tonyandrewmeyer merged 3 commits into
canonical:mainfrom
tonyandrewmeyer:fix-load-empty-keys

Conversation

@tonyandrewmeyer
Copy link
Copy Markdown
Contributor

Viper drops nil value keys when loading YAML, which means that a Concierge config that uses a nil value key to indicate that something should happen (like enabling specific features) doesn't work.

We already have a workaround for this for Snap entries, so this PR re-uses that to apply it to the K8s features as well (microk8s uses a list, lxd and google don't have similar items).

Fixes #189

Comment thread internal/config/presets.go
@tonyandrewmeyer tonyandrewmeyer merged commit d6548eb into canonical:main May 19, 2026
37 checks passed
@tonyandrewmeyer tonyandrewmeyer deleted the fix-load-empty-keys branch May 19, 2026 02:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Some k8s features are being ignored

2 participants