Skip to content

Commit

Permalink
Added upgrade/downgrade script template
Browse files Browse the repository at this point in the history
Refactored code
Addon upgrade/downgrade test similar to aws#1795

Added tests for addon upgrade/downgrade

Changed DEFAULT version
Added addon status checks

Fetch latest addon version for given K8s Cluster

Update kops cluster config used in weekly tests (aws#1862)

* Change to kops cluster creation scripts

* Add logging for retry attempt

* Switch kops cluster to use docker container runtime

Co-authored-by: Jayanth Varavani <1111446+jayanthvn@users.noreply.github.com>

Added upgrade/downgrade test for custom cni-manifest-file

Added missing files

remove upgrade-downgrade.sh
  • Loading branch information
Chinmay Gadgil committed Feb 15, 2022
1 parent a37a539 commit 1398c56
Show file tree
Hide file tree
Showing 10 changed files with 381 additions and 494 deletions.
249 changes: 0 additions & 249 deletions scripts/upload-resources-to-github.sh

This file was deleted.

22 changes: 15 additions & 7 deletions test/framework/options.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,17 @@ func init() {
}

type Options struct {
KubeConfig string
ClusterName string
AWSRegion string
AWSVPCID string
NgNameLabelKey string
NgNameLabelVal string
EKSEndpoint string
KubeConfig string
ClusterName string
AWSRegion string
AWSVPCID string
NgNameLabelKey string
NgNameLabelVal string
EKSEndpoint string
InitialAddon string
TargetAddon string
InitialManifest string
TargetManifest string
}

func (options *Options) BindFlags() {
Expand All @@ -44,6 +48,10 @@ func (options *Options) BindFlags() {
flag.StringVar(&options.NgNameLabelKey, "ng-name-label-key", "eks.amazonaws.com/nodegroup", "label key used to identify nodegroup name")
flag.StringVar(&options.NgNameLabelVal, "ng-name-label-val", "", "label value with the nodegroup name")
flag.StringVar(&options.EKSEndpoint, "eks-endpoint", "", "optional eks api server endpoint")
flag.StringVar(&options.InitialAddon, "initial-addon-version", "", "Initial CNI addon version before upgrade applied")
flag.StringVar(&options.TargetAddon, "target-addon-version", "", "Target CNI addon version after upgrade applied")
flag.StringVar(&options.InitialManifest, "initial-manifest-file", "", "Initial CNI manifest, can be local file path or remote Url")
flag.StringVar(&options.TargetManifest, "target-manifest-file", "", "Target CNI manifest, can be local file path or remote Url")
}

func (options *Options) Validate() error {
Expand Down
64 changes: 0 additions & 64 deletions test/framework/resources/aws/services/eks.go

This file was deleted.

1 change: 1 addition & 0 deletions test/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ require (
github.com/aws/amazon-vpc-cni-k8s/test/agent v0.0.0-20211209222755-86ece934e91a
github.com/aws/amazon-vpc-resource-controller-k8s v1.0.7
github.com/aws/aws-sdk-go v1.40.6
github.com/go-errors/errors v1.4.2
github.com/onsi/ginkgo v1.12.1
github.com/onsi/gomega v1.11.0
github.com/pkg/errors v0.9.1
Expand Down
2 changes: 2 additions & 0 deletions test/go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,8 @@ github.com/ghodss/yaml v1.0.0 h1:wQHKEahhL6wmXdzwWG11gIVCkOv05bNOh+Rxn0yngAk=
github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04=
github.com/globalsign/mgo v0.0.0-20180905125535-1ca0a4f7cbcb/go.mod h1:xkRDCp4j0OGD1HRkm4kmhM+pmpv3AKq5SU7GMg4oO/Q=
github.com/globalsign/mgo v0.0.0-20181015135952-eeefdecb41b8/go.mod h1:xkRDCp4j0OGD1HRkm4kmhM+pmpv3AKq5SU7GMg4oO/Q=
github.com/go-errors/errors v1.4.2 h1:J6MZopCL4uSllY1OfXM374weqZFFItUbrImctkmUxIA=
github.com/go-errors/errors v1.4.2/go.mod h1:sIVyrIiJhuEF+Pj9Ebtd6P/rEYROXFi3BopGUQ5a5Og=
github.com/go-ini/ini v1.25.4/go.mod h1:ByCAeIL28uOIIG0E3PJtZPDL8WnHpFKFOtgjp+3Ies8=
github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as=
github.com/go-kit/kit v0.9.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as=
Expand Down
Loading

0 comments on commit 1398c56

Please sign in to comment.