Skip to content

Commit

Permalink
+ Added SDK version in the log
Browse files Browse the repository at this point in the history
+ Update version in README + command
  • Loading branch information
ROunofF committed Nov 30, 2023
1 parent 8fe636e commit dd09d59
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
7 changes: 4 additions & 3 deletions cluster-autoscaler/cloudprovider/aws/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -429,13 +429,14 @@ To refresh static list, please run `go run ec2_instance_types/gen.go` under

If you want to use a newer version of the AWS SDK than the version currently vendored as a direct dependency by Cluster Autoscaler, then you can use the version vendored under this AWS cloudprovider.

The current version vendored is `v1.44.24`.
The current version vendored is `v1.48.7`.

If you want to update the vendored AWS SDK to a newer version, please make sure of the following:

1. Place the copy of the new desired version of the AWS SDK under the `aws-sdk-go` directory.
2. Update the import statements within the newly-copied AWS SDK to reference the new paths (e.g., `github.com/aws/aws-sdk-go/aws/awsutil` -> `k8s.io/autoscaler/cluster-autoscaler/cloudprovider/aws/aws-sdk-go/aws/awsutil`).
3. Update the version number above to indicate the new vendored version.
2. Remove folders : models and examples. Remove _test.go file `find . -name '*_test.go' -exec rm {}+`
3. Update the import statements within the newly-copied AWS SDK to reference the new paths (e.g., `github.com/aws/aws-sdk-go/aws/awsutil` -> `k8s.io/autoscaler/cluster-autoscaler/cloudprovider/aws/aws-sdk-go/aws/awsutil`). You can use this command from the aws-sdk-go folder `find . -type f -exec sed -i ‘s#github.com/aws/aws-sdk-go#k8s.io/autoscaler/cluster-autoscaler/cloudprovider/aws/aws-sdk-go#’ {} \;`
4. Update the version number above to indicate the new vendored version.

## Using cloud config with helm

Expand Down
2 changes: 2 additions & 0 deletions cluster-autoscaler/cloudprovider/aws/aws_manager.go
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,8 @@ func createAWSManagerInternal(
awsService *awsWrapper,
instanceTypes map[string]*InstanceType,
) (*AwsManager, error) {
klog.Infof("AWS SDK Version: %s", aws.SDKVersion)

if awsService == nil {
sess := awsSDKProvider.session
awsService = &awsWrapper{autoscaling.New(sess), ec2.New(sess), eks.New(sess)}
Expand Down

0 comments on commit dd09d59

Please sign in to comment.