mirror of
https://github.com/dredx/prole.git
synced 2026-09-23 12:03:59 +00:00
Rename env config files from conf/*/prole.cfg to conf/k3d.cfg, conf/k3s.cfg, and conf/gke.cfg. Update shell/Python loaders and etc/deploy scripts to resolve named configs cleanly while keeping legacy fallback behavior. Align k3s Ansible tasks, docs, and regression coverage with the new configuration layout. Co-authored-by: Junie <junie@jetbrains.com>
1.7 KiB
1.7 KiB
Prole configuration environments
Prole treats $PROLE_CONF as an explicit set of deployment-specific configs.
Directory layout
Under $PROLE_CONF:
$PROLE_CONF/k3d.cfg -> base config (k3d / dev)
$PROLE_CONF/k3s.cfg -> base config (k3s / service)
$PROLE_CONF/gke.cfg -> base config (k8s / prod)
$PROLE_CONF/test.cfg -> base config (test, optional)
Legacy layouts are still recognized for compatibility:
$PROLE_CONF/prole.cfg -> legacy entrypoint
$PROLE_CONF/<env>/prole.cfg -> legacy env base config
Activation (selecting the active environment)
- The active environment is inferred from
CLUSTER_ENV,PROLE_MODE, orDEPLOYMENT_MODE. - Resolution prefers named root files (
k3d.cfg,k3s.cfg,gke.cfg) and only falls back to legacyprole.cfgpaths. - Switching environments changes which named file is selected; it does not overwrite other environment configs.
If a legacy prole.cfg regular file is detected, migration preserves it as prole.cfg.legacy.<timestamp> and promotes content into the appropriate named file.
Override layering (deterministic merge)
- Named root configs (
k3d.cfg,k3s.cfg,gke.cfg,test.cfg) are loaded directly. - Legacy env-directory layout still supports layered
*.cfgoverrides in lexicographic filename order.
Later files override earlier values (last write wins).
Why this prevents accidental namespace drift
- k3d, k3s, and k8s/GKE are cleanly separated by dedicated config files.
- Mode/environment selection is explicit via deployment hints instead of mutable symlink state.
- Legacy configs remain readable during transition, reducing migration risk.