Fix pre-deployment wizard execution and return handling
- Changed menu to run wizard as subprocess instead of exec - Removed wizard's exec of menu since it now returns naturally - Wizard now properly returns to menu on completion or error - Prevents terminal freezing when wizard crashes
This commit is contained in:
@@ -254,10 +254,14 @@ handle_config_menu() {
|
|||||||
case "$choice" in
|
case "$choice" in
|
||||||
1)
|
1)
|
||||||
print_info "Starting interactive pre-deployment wizard..."
|
print_info "Starting interactive pre-deployment wizard..."
|
||||||
print_info "The menu will exit to allow the wizard to run. The menu will restart after completion."
|
print_info "The wizard will run and return to this menu when complete."
|
||||||
echo
|
echo
|
||||||
read -rp "Press Enter to continue..."
|
read -rp "Press Enter to continue..."
|
||||||
exec ./pre-deployment-wizard.sh
|
if ./pre-deployment-wizard.sh; then
|
||||||
|
print_success "Pre-deployment wizard completed successfully"
|
||||||
|
else
|
||||||
|
print_error "Pre-deployment wizard exited with an error"
|
||||||
|
fi
|
||||||
;;
|
;;
|
||||||
2)
|
2)
|
||||||
print_info "Localizing configuration templates..."
|
print_info "Localizing configuration templates..."
|
||||||
|
|||||||
@@ -365,6 +365,9 @@ main() {
|
|||||||
print_info "3. Run: ./localize.sh"
|
print_info "3. Run: ./localize.sh"
|
||||||
print_info "4. Run: ./deploy.sh core"
|
print_info "4. Run: ./deploy.sh core"
|
||||||
|
|
||||||
|
echo ""
|
||||||
|
print_info "Returning to EZ-Homelab menu..."
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user