File tree Expand file tree Collapse file tree 2 files changed +7
-21
lines changed
.pipelines/swiftv2-long-running/scripts Expand file tree Collapse file tree 2 files changed +7
-21
lines changed Original file line number Diff line number Diff line change @@ -22,7 +22,7 @@ VN_SUB_MAP["vnet_b1"]="s1"
2222PN_PREFIX=" pn-${BUILD_ID} "
2323PNI_PREFIX=" pni-${BUILD_ID} "
2424
25- source ./helpers_network_ids .sh
25+ source ./get_vnet_data .sh
2626
2727# Create PodNetwork in a specific cluster
2828create_pn () {
@@ -43,12 +43,7 @@ create_pn() {
4343 echo " SUBNET_ARM_ID: $SUBNET_ARM_ID "
4444
4545 # --- Create PodNetwork ---
46- ./create_pn.sh \
47- " $cluster_context " \
48- " $pn_name " \
49- " $VNET_GUID " \
50- " $SUBNET_GUID " \
51- " $SUBNET_ARM_ID "
46+ ./create_pn.sh " $cluster_context " " $pn_name " " $VNET_GUID " " $SUBNET_GUID " " $SUBNET_ARM_ID "
5247
5348 echo " PodNetwork ${pn_name} submitted successfully."
5449}
@@ -100,7 +95,7 @@ for i in 0 1; do
10095 create_pod_on_node " $CLUSTER2 " " $PN_C2 " " $PNI_C2 " " $NODE_NAME " " $POD_NAME "
10196done
10297
103- # # --- Part 2: Other PNs/PNIs across multiple subnets ---
98+ # --- Part 2: Other PNs/PNIs across multiple subnets ---
10499# PN_LIST=()
105100# PNI_LIST=()
106101
112107# PNI_LIST+=("$PNI_NAME")
113108# # Assume cluster selection: default to aks-1 unless aks-2 needs pods
114109# CLUSTER="$CLUSTER1"
115- # create_pn "$CLUSTER " "$PN_NAME"
116- # create_pni "$CLUSTER " "$PNI_NAME" "$PN_NAME" "$vnet " "$subnet "
110+ # create_pn "/tmp/${CLUSTER1}.kubeconfig " "$PN_NAME" "$vnet" "$subnet "
111+ # create_pni "/tmp/${CLUSTER1}.kubeconfig " "$PN_NAME" "$ PNI_NAME" "$PN_NAME" "explicit " "2" "$CLUSTER1 "
117112# done
118113# done
119114
Original file line number Diff line number Diff line change @@ -8,11 +8,7 @@ get_subnet_arm_id() {
88 local vnet=" $2 "
99 local subnet=" $3 "
1010
11- az network vnet subnet show \
12- --resource-group " $rg " \
13- --vnet-name " $vnet " \
14- --name " $subnet " \
15- --query " id" -o tsv
11+ az network vnet subnet show --resource-group " $rg " --vnet-name " $vnet " --name " $subnet " --query " id" -o tsv
1612}
1713
1814# === FUNCTION: Get Subnet GUID (SAL token) ===
@@ -24,11 +20,7 @@ get_subnet_guid() {
2420
2521 local subnet_id
2622 subnet_id=$( get_subnet_arm_id " $rg " " $vnet " " $subnet " )
27-
28- az resource show \
29- --ids " $subnet_id " \
30- --api-version 2023-09-01 \
31- --query " properties.serviceAssociationLinks[0].properties.subnetId" -o tsv
23+ az resource show --ids " $subnet_id " --api-version 2023-09-01 --query " properties.serviceAssociationLinks[0].properties.subnetId" -o tsv
3224}
3325
3426# === FUNCTION: Get VNET GUID ===
@@ -40,6 +32,5 @@ get_vnet_guid() {
4032
4133 local vnet_id
4234 vnet_id=$( az network vnet show --resource-group " $rg " --name " $vnet " --query " id" -o tsv)
43-
4435 echo " $vnet_id "
4536}
You can’t perform that action at this time.
0 commit comments