mirror of
https://github.com/dredx/prole.git
synced 2026-09-23 12:03:59 +00:00
Summary: Removed the prole-db-manager microservice and simplified deployment to use prole-authority as the internal management and authorization point. Fixed two blocking bugs that prevented silent install from completing on knoe-dev-cluster. Removed: prole-db-manager - Deleted db-manager-deployment.yaml and db-manager-service.yaml from opentofu manifests - Deleted src/db-manager/ (Dockerfile, server.js, package.json, tests) - Removed prole-db-manager port-forward mapping from installer/core/env.py - Removed init_db_manager.sh from Initialization Scripts (milestones.py, actions.py) - Removed init_certmgr.sh and init_db_manager.sh tabs from services screen (services.py) - Removed live k8s Deployment/Service from knoe-dev-cluster Fixed: PostgreSQL version downgrade error (pg17 -> pg18) - Created conf/postgresql/.version with value 18 - Updated k8s/prole/prole-db.yaml and prole-db-recovery.yaml.tpl imageName to prole-db:18-089 - Fixed _init_database_options_state() to restore saved version_type from prole.cfg so db_version_type defaults to v18 (pg18) instead of silently reverting to pg17 - Added database_options.* keys to _collect_input_snapshot() in cfg.py so distribution, version_type, and all extension toggles persist to prole.cfg Fixed: Cluster name inconsistency - Removed stale prole-dev-cluster references; all scripts now use knoe-dev-cluster - Added knoe-dev-cluster to mode-detection case in etc/prole_cfg.sh Config: conf/prole.cfg - Set kerberos_config.enabled = False, KERBEROS_AUTO_ENABLED = False - Added database_options.distribution = percona, version_type = v18 - Added all 13 extension flags set to True (postgis, pgvector, pgcrypto, pgaudit, pg_repack, pg_stat_statements, pg_buffercache, pg_freespacemap, pgrowlocks, postgres_fdw, dblink, pg_stat_monitor, pgbadger) Verification: ./install.py -s -l -v -c conf/prole.cfg completed successfully. CNPG deployed prole-db:18-089 to knoe-dev-cluster; all milestones passed. Co-authored-by: Junie <junie@jetbrains.com>
71 lines
1.6 KiB
Bash
Executable File
71 lines
1.6 KiB
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
set -euo pipefail
|
|
|
|
# init_common_core.sh
|
|
# Launch wrapper that runs all common core services (OpenBao, OpenTofu, Garage, ArgoCD)
|
|
# with a unified interface.
|
|
|
|
SCRIPT_DIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)
|
|
|
|
# shellcheck disable=SC1090
|
|
source "$SCRIPT_DIR/common_core_lib.sh"
|
|
|
|
common_core_preparse_config "$@"
|
|
|
|
# shellcheck disable=SC1090
|
|
source "$SCRIPT_DIR/prole_cfg.sh"
|
|
|
|
set -- "${COMMON_CORE_ARGS[@]}"
|
|
common_core_parse_args "$@"
|
|
|
|
if [[ "${COMMON_CORE_HELP:-0}" == 1 ]]; then
|
|
common_core_usage "$0"
|
|
exit 0
|
|
fi
|
|
|
|
if [[ -n "${COMMON_CORE_PARSE_ERROR:-}" ]]; then
|
|
echo "ERROR: ${COMMON_CORE_PARSE_ERROR}" >&2
|
|
common_core_usage "$0"
|
|
exit 2
|
|
fi
|
|
|
|
ACTION="$COMMON_CORE_ACTION"
|
|
|
|
TARGET_NAMESPACE="$(common_core_resolve_namespace "default")"
|
|
common_core_apply_namespace "$TARGET_NAMESPACE"
|
|
|
|
# Forwarded option bundles for child scripts
|
|
NS_ARGS=("-n" "$TARGET_NAMESPACE")
|
|
if [[ -n "${COMMON_CORE_NAMESPACE:-}" ]]; then
|
|
NS_ARGS=("-n" "$COMMON_CORE_NAMESPACE")
|
|
fi
|
|
MODE_ARGS=()
|
|
if [[ -n "${PROLE_MODE:-}" ]]; then
|
|
MODE_ARGS=("--mode" "$PROLE_MODE")
|
|
fi
|
|
CFG_ARGS=()
|
|
if [[ -n "${COMMON_CORE_CONFIG_PATH:-}" ]]; then
|
|
CFG_ARGS=("-c" "$COMMON_CORE_CONFIG_PATH")
|
|
fi
|
|
|
|
COMPONENTS=(
|
|
"openbao"
|
|
"opentofu"
|
|
"garage_store"
|
|
"argocd"
|
|
)
|
|
|
|
for comp in "${COMPONENTS[@]}"; do
|
|
script="$SCRIPT_DIR/init_${comp}.sh"
|
|
if [[ ! -x "$script" ]]; then
|
|
echo "WARN: missing script $script; skipping." >&2
|
|
continue
|
|
fi
|
|
echo ">>> init_${comp}.sh ${ACTION} (namespace=${NS_ARGS[1]})"
|
|
if ! "$script" "$ACTION" "${NS_ARGS[@]}" "${MODE_ARGS[@]}" "${CFG_ARGS[@]}"; then
|
|
echo "ERROR: init_${comp}.sh ${ACTION} failed" >&2
|
|
exit 1
|
|
fi
|
|
done
|