feat: add config-sets support #8

Merged
moritz merged 2 commits from eCommons/alakazam:config-sets into main 2026-06-01 16:34:04 +00:00
Contributor

Adds support for a config-sets.yml file at the root path where named bundles
of app configurations (env, hooks, secrets) can be defined and activated
per-instance or per-group, eliminating duplication across instance configs.

  • Config-sets are defined as top-level keys in config-sets.yml
  • Activate a set in any instance or group alaka.yml with CONFIG-SETS: : true
  • Disable a set inherited from a group with CONFIG-SETS: : false
  • Merge priority: group < config-set < instance
  • Warns when a config-set is enabled but not defined in config-sets.yml
  • Warns when a config-set targets an app not listed in the instance config
  • Adds examples/config-sets.yml with bbb and calendar config-set examples

See #3

Adds support for a config-sets.yml file at the root path where named bundles of app configurations (env, hooks, secrets) can be defined and activated per-instance or per-group, eliminating duplication across instance configs. - Config-sets are defined as top-level keys in config-sets.yml - Activate a set in any instance or group alaka.yml with CONFIG-SETS: <name>: true - Disable a set inherited from a group with CONFIG-SETS: <name>: false - Merge priority: group < config-set < instance - Warns when a config-set is enabled but not defined in config-sets.yml - Warns when a config-set targets an app not listed in the instance config - Adds examples/config-sets.yml with bbb and calendar config-set examples See #3
dannygroenewegen added 1 commit 2026-05-28 10:05:33 +00:00
Adds support for a config-sets.yml file at the root path where named bundles
of app configurations (env, hooks, secrets) can be defined and activated
per-instance or per-group, eliminating duplication across instance configs.

- Config-sets are defined as top-level keys in config-sets.yml
- Activate a set in any instance or group alaka.yml with CONFIG-SETS: <name>: true
- Disable a set inherited from a group with CONFIG-SETS: <name>: false
- Merge priority: group < config-set < instance
- Warns when a config-set is enabled but not defined in config-sets.yml
- Warns when a config-set targets an app not listed in the instance config
- Adds examples/config-sets.yml with bbb and calendar config-set examples
dannygroenewegen requested review from moritz 2026-05-28 10:05:49 +00:00
dannygroenewegen requested review from simon 2026-05-28 10:05:59 +00:00
moritz requested changes 2026-06-01 13:33:36 +00:00
moritz left a comment
Owner

🚀🚀🚀 this feature we were missing a lot!
I already created the kolli-cloud config set: b8243be801
The only thing whats missing in this PR are the docs in the Readme, how to use the config-set or an reference to the example file, everything else looks perfect.

🚀🚀🚀 this feature we were missing a lot! I already created the kolli-cloud config set: https://git.local-it.org/local-it/kolli-config/commit/b8243be8015c34f22bf77a393b66d039b4104a80 The only thing whats missing in this PR are the docs in the Readme, how to use the config-set or an reference to the example file, everything else looks perfect.
@ -237,0 +280,4 @@
config_set_app_config = config_set_app_configs.get(app) or {}
instance_app_config = instance_apps[app] or {}
# Priority: group < config-set < instance
merged_config[app] = merge_dict(merge_dict(group_app_config, config_set_app_config), instance_app_config)
Owner

I really like how you structured the code in this function. This makes it much more readable and expandable.

I really like how you structured the code in this function. This makes it much more readable and expandable.
alakazam.py Outdated
@ -281,2 +323,4 @@
dict: A dictionary with domains as keys and their respective merged configurations as values.
"""
if config_sets is None:
config_sets = {}
Owner

These lines are redundant, as they are set in merge_instance_configs as well and only used in merge_instance_configs.

These lines are redundant, as they are set in `merge_instance_configs` as well and only used in `merge_instance_configs`.
dannygroenewegen marked this conversation as resolved
dannygroenewegen added 1 commit 2026-06-01 15:48:29 +00:00
dannygroenewegen requested review from moritz 2026-06-01 15:49:15 +00:00
moritz merged commit 70ce2fee7b into main 2026-06-01 16:34:04 +00:00
dannygroenewegen deleted branch config-sets 2026-06-01 19:28:11 +00:00
Sign in to join this conversation.
No description provided.