Skip to content

Commit

Permalink
make dir if missing
Browse files Browse the repository at this point in the history
  • Loading branch information
badra001 committed Apr 1, 2021
1 parent cc251df commit b748097
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions iam-saml/bin/external_get-saml-metadata.sh
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,12 @@ then
OUTPUT="metadata.$(date +%s).xml"
fi

OUTDIR=$(dirname $OUTPUT)
if [ ! -d $OUTDIR ]
then
mkdir -p $OUTDIR
fi

URL="${URL_PREFIX}${SELECT}"
curl -q -k $URL > $OUTPUT
status=$?
Expand Down

0 comments on commit b748097

Please sign in to comment.