feat: add --dry-run option for read-only infrastructure state check
This commit is contained in:
@@ -11,6 +11,7 @@ set -euo pipefail
|
||||
# ./run_all.sh --skip-setup # Skip setup scripts, start at preflight
|
||||
# ./run_all.sh --start-from=3 # Run preflight, then start at phase 3
|
||||
# ./run_all.sh --skip-setup --start-from=5
|
||||
# ./run_all.sh --dry-run # Read-only infrastructure state check
|
||||
# =============================================================================
|
||||
|
||||
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
|
||||
@@ -31,6 +32,9 @@ START_FROM_SET=false
|
||||
for arg in "$@"; do
|
||||
case "$arg" in
|
||||
--skip-setup) SKIP_SETUP=true ;;
|
||||
--dry-run)
|
||||
exec "${SCRIPT_DIR}/post-migration-check.sh"
|
||||
;;
|
||||
--start-from=*)
|
||||
START_FROM="${arg#*=}"
|
||||
START_FROM_SET=true
|
||||
@@ -50,12 +54,14 @@ Usage: $(basename "$0") [options]
|
||||
Options:
|
||||
--skip-setup Skip configure_env + machine setup, start at preflight
|
||||
--start-from=N Skip phases before N (still runs preflight)
|
||||
--dry-run Run read-only infrastructure check (no mutations)
|
||||
--help Show this help
|
||||
|
||||
Examples:
|
||||
$(basename "$0") Full run
|
||||
$(basename "$0") --skip-setup Skip setup, start at preflight
|
||||
$(basename "$0") --start-from=3 Run preflight, then phases 3-9
|
||||
$(basename "$0") --dry-run Check current state without changing anything
|
||||
EOF
|
||||
exit 0 ;;
|
||||
*) log_error "Unknown argument: $arg"; exit 1 ;;
|
||||
|
||||
Reference in New Issue
Block a user