oras-project / oras-go

ORAS Go library

Home Page:https://oras.land

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

types.AuthConfig is deprecated in docker v25.x.x

yp05327 opened this issue · comments

When I build my application, I got this error:

# oras.land/oras-go/pkg/auth/docker
/go/pkg/mod/oras.land/oras-go@v1.2.4/pkg/auth/docker/login_tls.go:44:20: undefined: types.AuthConfig
/go/pkg/mod/oras.land/oras-go@v1.2.4/pkg/auth/docker/login_tls.go:62:131: undefined: types.AuthConfig
/go/pkg/mod/oras.land/oras-go@v1.2.4/pkg/auth/docker/login_tls.go:122:32: undefined: types.AuthConfig
/go/pkg/mod/oras.land/oras-go@v1.2.4/pkg/auth/docker/login.go:54:16: undefined: types.AuthConfig

Then I found that types.AuthConfig is deprecated in github.com/docker/docker@v25.x.x.
https://pkg.go.dev/github.com/docker/docker@v24.0.7+incompatible/api/types#AuthConfig

But github.com/docker/docker was updated from v24.0.7 to v25.0.0 in #689 yesterday.

Hi @yp05327 , it looks like your code is still using v1.2.4which does not include the latest dependency updates.
To use the latest commit 2afb687, you can run:

go get oras.land/oras-go@2afb6872ee1aefbdb5bfdbdaa15833cad8244b80

Hi @Wwwsylvia, it worked. Thanks a lot.