Skip to content

Commit

Permalink
Merge branch 'main' into chore/v1-migration
Browse files Browse the repository at this point in the history
  • Loading branch information
rschalo authored Jul 12, 2024
2 parents d1ba8b5 + 5baf0d7 commit 565675e
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 9 deletions.
16 changes: 8 additions & 8 deletions .github/workflows/e2e-upgrade.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,14 @@ jobs:
- uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 # v4.1.2
with:
ref: ${{ inputs.to_git_ref }}
- name: upgrade crds
uses: ./.github/actions/e2e/upgrade-crds
with:
account_id: ${{ vars.CI_ACCOUNT_ID }}
role: ${{ vars.CI_ROLE_NAME }}
region: ${{ inputs.region }}
cluster_name: ${{ steps.generate-cluster-name.outputs.CLUSTER_NAME }}
git_ref: ${{ inputs.to_git_ref }}
- name: upgrade eks cluster '${{ steps.generate-cluster-name.outputs.CLUSTER_NAME }}'
uses: ./.github/actions/e2e/setup-cluster
with:
Expand All @@ -116,14 +124,6 @@ jobs:
ecr_region: ${{ vars.SNAPSHOT_REGION }}
prometheus_workspace_id: ${{ vars.WORKSPACE_ID }}
prometheus_region: ${{ vars.PROMETHEUS_REGION }}
- name: upgrade crds
uses: ./.github/actions/e2e/upgrade-crds
with:
account_id: ${{ vars.CI_ACCOUNT_ID }}
role: ${{ vars.CI_ROLE_NAME }}
region: ${{ inputs.region }}
cluster_name: ${{ steps.generate-cluster-name.outputs.CLUSTER_NAME }}
git_ref: ${{ inputs.to_git_ref }}
- name: run the Upgrade test suite
run: |
aws eks update-kubeconfig --name ${{ steps.generate-cluster-name.outputs.CLUSTER_NAME }}
Expand Down
9 changes: 8 additions & 1 deletion test/suites/drift/suite_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -547,6 +547,8 @@ var _ = Describe("Drift", func() {
Kind: object.GVK(nodeClass).Kind,
Name: nodeClass.Name,
},
// keep the same instance type requirements to prevent considering instance types that require swap
Requirements: nodePool.Spec.Template.Spec.Requirements,
},
},
},
Expand Down Expand Up @@ -612,7 +614,12 @@ var _ = Describe("Drift", func() {
}),
Entry("NodeRequirements", karpv1.NodeClaimTemplate{
Spec: karpv1.NodeClaimSpec{
Requirements: []karpv1.NodeSelectorRequirementWithMinValues{{NodeSelectorRequirement: corev1.NodeSelectorRequirement{Key: karpv1.CapacityTypeLabelKey, Operator: corev1.NodeSelectorOpIn, Values: []string{karpv1.CapacityTypeSpot}}}},
// since this will overwrite the default requirements, add instance category and family selectors back into requirements
Requirements: []corev1beta1.NodeSelectorRequirementWithMinValues{

Check failure on line 618 in test/suites/drift/suite_test.go

View workflow job for this annotation

GitHub Actions / ci

undefined: corev1beta1 (typecheck)
{NodeSelectorRequirement: corev1.NodeSelectorRequirement{Key: karpv1.CapacityTypeLabelKey, Operator: corev1.NodeSelectorOpIn, Values: []string{karpv1.CapacityTypeSpot}}},
{NodeSelectorRequirement: corev1.NodeSelectorRequirement{Key: v1.LabelInstanceCategory, Operator: corev1.NodeSelectorOpIn, Values: []string{"c", "m", "r"}}},
{NodeSelectorRequirement: corev1.NodeSelectorRequirement{Key: v1.LabelInstanceFamily, Operator: corev1.NodeSelectorOpNotIn, Values: []string{"a1"}}},
},
},
}),
)
Expand Down

0 comments on commit 565675e

Please sign in to comment.