-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
1 parent
a4f0d90
commit c24daf7
Showing
4 changed files
with
101 additions
and
4 deletions.
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,21 @@ | ||
#!/usr/bin/env bash | ||
set -euo pipefail | ||
|
||
echo "-> Should calc max-pods successfully for c6in.32xlarge VPC CNI 1.18.0" | ||
exit_code=0 | ||
out=$(/etc/eks/max-pods-calculator.sh \ | ||
--instance-type c6in.32xlarge \ | ||
--cni-version 1.18.0 \ | ||
--show-max-allowed || exit_code=$?) | ||
echo $out | ||
|
||
if [[ ${exit_code} -ne 0 ]]; then | ||
echo "❌ Test Failed: expected a non-zero exit code but got '${exit_code}'" | ||
exit 1 | ||
fi | ||
expected_max_pods="394" | ||
actual_max_pods=$(grep -o '[0-9]\+' <<< ${out}) | ||
if [[ ${actual_max_pods} -ne ${expected_max_pods} ]]; then | ||
echo "❌ Test Failed: expected max-pods for c6in.32xlarge w/ CNI 1.18.5 to be '${expected_max_pods}', but got '${actual_max_pods}'" | ||
exit 1 | ||
fi |
36 changes: 36 additions & 0 deletions
36
templates/test/mocks/describe-instance-types/c6in-32xlarge.json
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,36 @@ | ||
{ | ||
"Hypervisor": "nitro", | ||
"NetworkInfo": { | ||
"NetworkPerformance": "200 Gigabit", | ||
"MaximumNetworkInterfaces": 16, | ||
"MaximumNetworkCards": 2, | ||
"DefaultNetworkCardIndex": 0, | ||
"NetworkCards": [ | ||
{ | ||
"NetworkCardIndex": 0, | ||
"NetworkPerformance": "Up to 170 Gigabit", | ||
"MaximumNetworkInterfaces": 8, | ||
"BaselineBandwidthInGbps": 200.0, | ||
"PeakBandwidthInGbps": 200.0 | ||
}, | ||
{ | ||
"NetworkCardIndex": 1, | ||
"NetworkPerformance": "Up to 170 Gigabit", | ||
"MaximumNetworkInterfaces": 8, | ||
"BaselineBandwidthInGbps": 200.0, | ||
"PeakBandwidthInGbps": 200.0 | ||
} | ||
], | ||
"Ipv4AddressesPerInterface": 50, | ||
"Ipv6AddressesPerInterface": 50, | ||
"Ipv6Supported": true, | ||
"EnaSupport": "required", | ||
"EfaSupported": true, | ||
"EfaInfo": { | ||
"MaximumEfaInterfaces": 2 | ||
}, | ||
"EncryptionInTransitSupported": true, | ||
"EnaSrdSupported": false | ||
}, | ||
"CpuCount": 128 | ||
} |
24 changes: 22 additions & 2 deletions
24
templates/test/mocks/describe-instance-types/m4-xlarge.json
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 |
---|---|---|
@@ -1,6 +1,26 @@ | ||
{ | ||
"Hypervisor": "xen", | ||
"EniCount": 4, | ||
"PodsPerEniCount": 15, | ||
"NetworkInfo": { | ||
"NetworkPerformance": "High", | ||
"MaximumNetworkInterfaces": 4, | ||
"MaximumNetworkCards": 1, | ||
"DefaultNetworkCardIndex": 0, | ||
"NetworkCards": [ | ||
{ | ||
"NetworkCardIndex": 0, | ||
"NetworkPerformance": "High", | ||
"MaximumNetworkInterfaces": 4, | ||
"BaselineBandwidthInGbps": 0.75, | ||
"PeakBandwidthInGbps": 2.8 | ||
} | ||
], | ||
"Ipv4AddressesPerInterface": 15, | ||
"Ipv6AddressesPerInterface": 15, | ||
"Ipv6Supported": true, | ||
"EnaSupport": "unsupported", | ||
"EfaSupported": false, | ||
"EncryptionInTransitSupported": false, | ||
"EnaSrdSupported": false | ||
}, | ||
"CpuCount": 4 | ||
} |
24 changes: 22 additions & 2 deletions
24
templates/test/mocks/describe-instance-types/m5-8xlarge.json
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 |
---|---|---|
@@ -1,6 +1,26 @@ | ||
{ | ||
"Hypervisor": "nitro", | ||
"EniCount": 8, | ||
"PodsPerEniCount": 30, | ||
"NetworkInfo": { | ||
"NetworkPerformance": "10 Gigabit", | ||
"MaximumNetworkInterfaces": 8, | ||
"MaximumNetworkCards": 1, | ||
"DefaultNetworkCardIndex": 0, | ||
"NetworkCards": [ | ||
{ | ||
"NetworkCardIndex": 0, | ||
"NetworkPerformance": "10 Gigabit", | ||
"MaximumNetworkInterfaces": 8, | ||
"BaselineBandwidthInGbps": 10.0, | ||
"PeakBandwidthInGbps": 10.0 | ||
} | ||
], | ||
"Ipv4AddressesPerInterface": 30, | ||
"Ipv6AddressesPerInterface": 30, | ||
"Ipv6Supported": true, | ||
"EnaSupport": "required", | ||
"EfaSupported": false, | ||
"EncryptionInTransitSupported": false, | ||
"EnaSrdSupported": false | ||
}, | ||
"CpuCount": 32 | ||
} |