-
Notifications
You must be signed in to change notification settings - Fork 44
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor e2e tests to use kueue (#505)
Co-authored-by: Shilpa Chugh <[email protected]>
- Loading branch information
1 parent
b553e92
commit 979ff43
Showing
5 changed files
with
100 additions
and
84 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
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,53 @@ | ||
#!/bin/bash | ||
|
||
name=${name:-cluster-queue-mnist} | ||
flavor=${flavor:-default-flavor-mnist} | ||
local_queue_name=${local_queue_name:-local-queue-mnist} | ||
namespace=$1 | ||
|
||
echo "Applying Cluster Queue" | ||
|
||
cat <<EOF | kubectl apply --server-side -f - | ||
apiVersion: kueue.x-k8s.io/v1beta1 | ||
kind: ClusterQueue | ||
metadata: | ||
name: $name | ||
spec: | ||
namespaceSelector: {} | ||
resourceGroups: | ||
- coveredResources: ["cpu", "memory", "nvidia.com/gpu"] | ||
flavors: | ||
- name: "default-flavor-mnist" | ||
resources: | ||
- name: "cpu" | ||
nominalQuota: 9 | ||
- name: "memory" | ||
nominalQuota: 36Gi | ||
- name: "nvidia.com/gpu" | ||
nominalQuota: 0 | ||
EOF | ||
echo "Cluster Queue $name applied!" | ||
|
||
echo "Applying Resource flavor" | ||
cat <<EOF | kubectl apply --server-side -f - | ||
apiVersion: kueue.x-k8s.io/v1beta1 | ||
kind: ResourceFlavor | ||
metadata: | ||
name: $flavor | ||
EOF | ||
echo "Resource flavor $flavor applied!" | ||
|
||
echo "Applying local queue" | ||
|
||
cat <<EOF | kubectl apply --server-side -f - | ||
apiVersion: kueue.x-k8s.io/v1beta1 | ||
kind: LocalQueue | ||
metadata: | ||
namespace: $namespace | ||
name: $local_queue_name | ||
annotations: | ||
"kueue.x-k8s.io/default-queue": "true" | ||
spec: | ||
clusterQueue: $name | ||
EOF | ||
echo "Local Queue $local_queue_name applied!" |
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
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
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