Skip to content

Commit

Permalink
testing
Browse files Browse the repository at this point in the history
  • Loading branch information
JordanHoey96 committed Nov 20, 2024
1 parent 1502300 commit 9d691e3
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions scripts/aks/resource-details.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,7 @@ function get_costs() {
CLUSTERS=$(get_clusters)

while read cluster; do
RESOURCE_GROUP=$(jq -r '.resourceGroup' <<<$cluster)
cluster_name=$(jq -r '.name' <<<$cluster)
get_cluster_details
cluster_env=$(echo $cluster_name | cut -d'-' -f2)
cluster_env=${cluster_env/#sbox/Sandbox}
cluster_env=${cluster_env/stg/Staging}
Expand All @@ -54,7 +53,7 @@ function get_costs() {
justification=$(jq -r '. | last | .justification' issues_list.json)

if [[ ${env_entry} =~ ${cluster_env} ]] && [[ $cluster_business_area == $business_area_entry ]]; then
nodepool_details=$(az aks nodepool list --cluster-name $cluster_name --resource-group $RESOURCE_GROUP -o json)
nodepool_details=$(az aks nodepool list --cluster-name $CLUSTER_NAME --resource-group $RESOURCE_GROUP --subscription $SUBSCRIPTION -o json)
while read nodepool; do
nodepool_count=$(jq -r '."count"' <<< $nodepool)
nodepool_name=$(jq -r '."name"' <<< $nodepool)
Expand Down

0 comments on commit 9d691e3

Please sign in to comment.