fix: simplify AZURITE_ACCOUNTS check by removing default account generation
This commit is contained in:
@@ -4,14 +4,8 @@ set -euo pipefail
|
|||||||
|
|
||||||
# Check, if the AZURITE_ACCOUNTS variable is set
|
# Check, if the AZURITE_ACCOUNTS variable is set
|
||||||
if [[ -z "$AZURITE_ACCOUNTS" ]]; then
|
if [[ -z "$AZURITE_ACCOUNTS" ]]; then
|
||||||
if [[ -f "/storage/accounts.env" ]]; then
|
echo "Error: AZURITE_ACCOUNTS variable is not set." >&2
|
||||||
set -a
|
exit 1
|
||||||
source "/storage/accounts.env"
|
|
||||||
set +a
|
|
||||||
else
|
|
||||||
# Generate a default account
|
|
||||||
export AZURITE_ACCOUNTS="devstoreaccount1:$(openssl rand -base64 32)"
|
|
||||||
fi
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Look up the account name from the AZURITE_ACCOUNTS variable, which is in the format "accountName:accountKey1:accountKey2;accountName2:accountKey1:accountKey2"
|
# Look up the account name from the AZURITE_ACCOUNTS variable, which is in the format "accountName:accountKey1:accountKey2;accountName2:accountKey1:accountKey2"
|
||||||
|
|||||||
Reference in New Issue
Block a user