Permalink
Cannot retrieve contributors at this time
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
15 lines (9 sloc)
646 Bytes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -euo pipefail | |
az keyvault secret set --vault-name $KEY_VAULT_NAME --name AzureDatabricksToken --value $DATABRICKS_TOKEN | |
storageAccountKey=$(az storage account keys list -g $RESOURCE_GROUP_NAME -n $STORAGE_ACCOUNT_NAME --query "[0].value" | tr -d '"') | |
if ! databricks secrets list-scopes --output JSON | jq -e '.scopes[] | select (.name == "bikeshare")'; then | |
databricks secrets create-scope --scope bikeshare --initial-manage-principal "users" | |
fi | |
databricks secrets write --scope bikeshare --key storagekey --string-value $storageAccountKey | |
databricks fs cp --overwrite java-library/target/*.jar dbfs:/model-factory.jar | |