Skip to content

Commit

Permalink
Fix error in reading ironic htpasswd from file
Browse files Browse the repository at this point in the history
  • Loading branch information
MahnoorAsghar committed Apr 25, 2024
1 parent cfac9aa commit 08f50b3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions scripts/auth-common.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@ fi
set +x
IRONIC_HTPASSWD_FILE=/etc/ironic/htpasswd
if [[ -f "/auth/ironic/username" ]]; then
read -r IRONIC_HTPASSWD_USERNAME<"/auth/ironic/username"
read -r IRONIC_HTPASSWD_USERNAME<"/auth/ironic/username" || true
fi
IRONIC_HTPASSWD_USERNAME=${IRONIC_HTPASSWD_USERNAME:-}
if [[ -f "/auth/ironic/password" ]]; then
read -r IRONIC_HTPASSWD_PASSWORD<"/auth/ironic/password"
read -r IRONIC_HTPASSWD_PASSWORD<"/auth/ironic/password" || true
fi
IRONIC_HTPASSWD_PASSWORD=${IRONIC_HTPASSWD_PASSWORD:-}
if [[ -n "${IRONIC_HTPASSWD_USERNAME}" ]]; then
Expand Down

0 comments on commit 08f50b3

Please sign in to comment.