-
Notifications
You must be signed in to change notification settings - Fork 148
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
41 additions
and
1 deletion.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
#!/bin/bash | ||
|
||
# Parameters | ||
tre_id=$1 | ||
workspace_id=$2 | ||
workspace_service_id=$3 | ||
user_resource_id=$4 | ||
|
||
# Build the tag filter query | ||
tag_filters="--tag tre_resource_id=$tre_id" | ||
[ -n "$workspace_id" ] && tag_filters="$tag_filters --tag tre_workspace_id=$workspace_id" | ||
[ -n "$workspace_service_id" ] && tag_filters="$tag_filters --tag tre_workspace_service_id=$workspace_service_id" | ||
[ -n "$user_resource_id" ] && tag_filters="$tag_filters --tag tre_user_resource_id=$user_resource_id" | ||
|
||
# login to azure | ||
az login --identity | ||
|
||
# Get the resource IDs with the specified tags | ||
resource_ids=$(az resource list "$tag_filters" --query "[].id" -o tsv) | ||
|
||
# Delete the resources | ||
if [ -n "$resource_ids" ]; then | ||
az resource delete --ids "$resource_ids" --yes | ||
else | ||
echo "No resources found with the specified tags." | ||
fi |
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
1 change: 1 addition & 0 deletions
1
...kspace_services/guacamole/user_resources/guacamole-azure-linuxvm/porter-build-context.env
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export PORTER_BUILD_CONTEXT="scripts=../../../../scripts" |
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