Skip to content

Commit

Permalink
Improve checks
Browse files Browse the repository at this point in the history
  • Loading branch information
rbamos committed Jul 12, 2024
1 parent 073069f commit c353dcc
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 3 deletions.
12 changes: 12 additions & 0 deletions config.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,18 @@ else
. ./utils.sh
fi

if [[ -z "${INTEGRATION_PORTAL_URL}" ]]; then
red_echo "INTEGRATION_PORTAL_URL must be provided"
exit
fi

echo "$LINENO" >> /tmp/leapp-setup.log

if [[ -z "${LEAPP_ROLES}" ]]; then
red_echo "LEAPP_ROLES must be provided"
exit
fi

if [[ "$kernel_name" == "Darwin" ]]; then
# Leapp integration setup
LEAPP=/Applications/Leapp.app
Expand Down
6 changes: 3 additions & 3 deletions setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -40,14 +40,14 @@ fi

echo "$LINENO" >> /tmp/leapp-setup.log

if [[ "${CONFIGURE}" != "0" ]] && [[ -z "${INTEGRATION_PORTAL_URL}" ]]; then
if [[ "${CONFIGURE_LEAPP}" != "0" ]] && [[ -z "${INTEGRATION_PORTAL_URL}" ]]; then
red_echo "INTEGRATION_PORTAL_URL must be provided"
exit
fi

echo "$LINENO" >> /tmp/leapp-setup.log

if [[ "${CONFIGURE}" != "0" ]] && [[ -z "${LEAPP_ROLES}" ]]; then
if [[ "${CONFIGURE_LEAPP}" != "0" ]] && [[ -z "${LEAPP_ROLES}" ]]; then
red_echo "LEAPP_ROLES must be provided"
exit
fi
Expand Down Expand Up @@ -150,7 +150,7 @@ fi

echo "$LINENO" >> /tmp/leapp-setup.log

if [[ "${CONFIGURE}" == "0" ]]; then
if [[ "${CONFIGURE_LEAPP}" == "0" ]]; then
exit
fi

Expand Down

0 comments on commit c353dcc

Please sign in to comment.