reordered app name check

main
Daniel Mikula 2023-05-17 07:53:11 +02:00
parent 9de216c8c3
commit 2e69353029
1 changed files with 17 additions and 15 deletions

View File

@ -96,6 +96,21 @@ while [ "$#" -gt 0 ]; do
esac
done
# Validate app names
if [ -z "$app_name" ]; then
echo "Please specify app"
else
case $app_name in
"sock_shop")
echo "$app_name OK"
;;
*)
show_allowed_apps
exit 1
;;
esac
fi
# Check if --helm was set
if [ "$helm_install" = true ]; then
install_helm
@ -109,18 +124,5 @@ install_git
echo "Installing K3S"
install_k3s
# Validate app names
if [ -z "$app_name" ]; then
echo "Please specify app"
else
case $app_name in
"sock_shop")
echo "Installing sock shop"
echo "Installing $app_name"
install_sock_shop
;;
*)
show_allowed_apps
exit 1
;;
esac
fi