Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update docker client library to v23.0.3 in ecs-init #3635

Merged
merged 1 commit into from
Apr 14, 2023

Conversation

mythri-garaga
Copy link
Contributor

@mythri-garaga mythri-garaga commented Apr 10, 2023

Summary

We have a dependabot PR #3633 open to update docker client in ecs-init from 20.10.3-0.20210618090124-472f21b923ef+incompatible to 20.10.24+incompatible. The dependabot PR is failing with

Error: ecs-init/vendor/github.com/docker/docker/pkg/fileutils/fileutils.go:13:2: case-insensitive import collision: "github.com/aws/amazon-ecs-agent/ecs-init/vendor/github.com/sirupsen/logrus" and "github.com/aws/amazon-ecs-agent/ecs-init/vendor/github.com/Sirupsen/logrus"

and upon trying to resolve the case-insensitive import collision, there was another error while running linux tests

# github.com/aws/amazon-ecs-agent/ecs-init/vendor/github.com/docker/docker/opts
Error: ecs-init/vendor/github.com/docker/docker/opts/address_pools.go:15:18: undefined: ipamutils.NetworkToSplit
Error: ecs-init/vendor/github.com/docker/docker/opts/address_pools.go:31:20: undefined: ipamutils.NetworkToSplit
Error: ecs-init/vendor/github.com/docker/docker/opts/address_pools.go:77:37: undefined: ipamutils.NetworkToSplit

So this PR updates the docker client library to v23.0.3(latest version) in ecs-init to avoid the above failures

Implementation details

go get github.com/docker/docker@latest
go mod tidy
go vendor

Testing

New tests cover the changes:

  • Locally ran functional tests for al2023, al2023arm and al2023neu and they succeeded.
  • Pending testing on AMI with old docker version - 19.03.13

Description for the changelog

Enhancement: update docker client library to latest in ecs-init

Licensing

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@@ -46,5 +49,3 @@ replace github.com/coreos/go-systemd => github.com/coreos/go-systemd/v22 v22.0.0
replace golang.org/x/net => golang.org/x/net v0.0.0-20170529214944-3da985ce5951

replace github.com/jmespath/go-jmespath => github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af

replace github.com/pkg/errors => github.com/pkg/errors v0.8.1-0.20170505043639-c605e284fe17
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

removed this line as tests were failing with

go test -count=1 -short -v -coverprofile cover.out ./ecs-init/...
# github.com/aws/amazon-ecs-agent/ecs-init/vendor/github.com/docker/docker/pkg/archive
ecs-init/vendor/github.com/docker/docker/pkg/archive/archive.go:782:14: undefined: errors.Is

@mythri-garaga mythri-garaga changed the title [WIP] Update docker client library to v23.0.3 in ecs-init Update docker client library to v23.0.3 in ecs-init Apr 10, 2023
@mythri-garaga mythri-garaga marked this pull request as ready for review April 10, 2023 16:48
@mythri-garaga mythri-garaga requested a review from a team as a code owner April 10, 2023 16:48
Realmonia
Realmonia previously approved these changes Apr 10, 2023
Yiyuanzzz
Yiyuanzzz previously approved these changes Apr 10, 2023
@mythri-garaga
Copy link
Contributor Author

mythri-garaga commented Apr 10, 2023

Locally ran functional tests for al2023, al2023arm and al2023neu and they succeeded.

@mythri-garaga
Copy link
Contributor Author

rebased to include the fix #3638.

Copy link
Contributor

@YashdalfTheGray YashdalfTheGray left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, thanks for running the tests for AL2023 locally!

@mythri-garaga mythri-garaga merged commit 17b37d3 into aws:dev Apr 14, 2023
@Yiyuanzzz Yiyuanzzz mentioned this pull request Apr 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants