Skip to content

Commit 9cd0eb4

Browse files
authored
Merge branch 'main' into add-resumable-downloads
2 parents 345fc6a + c323c67 commit 9cd0eb4

File tree

5 files changed

+11
-8
lines changed

5 files changed

+11
-8
lines changed

.github/workflows/ecr-auth.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ jobs:
2828
run: go install .
2929

3030
- name: Configure AWS Credentials
31-
uses: aws-actions/configure-aws-credentials@v2.0.0
31+
uses: aws-actions/configure-aws-credentials@v5.1.0
3232
with:
3333
role-to-assume: arn:aws:iam::${{ env.AWS_ACCOUNT }}:role/federated-ecr-readonly
3434
aws-region: ${{ env.AWS_REGION }}
@@ -67,7 +67,7 @@ jobs:
6767
run: go install .
6868

6969
- name: Configure AWS Credentials
70-
uses: aws-actions/configure-aws-credentials@v2.0.0
70+
uses: aws-actions/configure-aws-credentials@v5.1.0
7171
with:
7272
role-to-assume: arn:aws:iam::${{ env.AWS_ACCOUNT }}:role/federated-ecr-readonly
7373
aws-region: ${{ env.AWS_REGION }}

.github/workflows/release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919
with:
2020
go-version: 1.21
2121
check-latest: true
22-
- uses: goreleaser/goreleaser-action@v4.2.0
22+
- uses: goreleaser/goreleaser-action@v6.4.0
2323
id: run-goreleaser
2424
with:
2525
version: "~> v1.19"
@@ -53,7 +53,7 @@ jobs:
5353
permissions: read-all
5454
steps:
5555
- name: Install SLSA verifier
56-
uses: slsa-framework/slsa-verifier/actions/installer@v2.7.0
56+
uses: slsa-framework/slsa-verifier/actions/installer@v2.7.1
5757
- name: Download assets
5858
env:
5959
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/test.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,4 @@ jobs:
1818

1919
- run: go test -coverprofile=coverage.txt -covermode=atomic -race ./...
2020

21-
- uses: codecov/codecov-action@v4.1.0
21+
- uses: codecov/codecov-action@v5.5.1

pkg/crane/copy.go

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,10 @@ import (
2626
"golang.org/x/sync/errgroup"
2727
)
2828

29+
// ErrRefusingToClobberExistingTag is returned when NoClobber is true and the
30+
// tag already exists in the target registry/repo.
31+
var ErrRefusingToClobberExistingTag = errors.New("refusing to clobber existing tag")
32+
2933
// Copy copies a remote image or index from src to dst.
3034
func Copy(src, dst string, opt ...Option) error {
3135
o := makeOptions(opt...)
@@ -58,7 +62,7 @@ func Copy(src, dst string, opt ...Option) error {
5862
}
5963

6064
if head != nil {
61-
return fmt.Errorf("refusing to clobber existing tag %s@%s", tag, head.Digest)
65+
return fmt.Errorf("%w %s@%s", ErrRefusingToClobberExistingTag, tag, head.Digest)
6266
}
6367
}
6468
}

pkg/v1/remote/options.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -169,8 +169,7 @@ func makeOptions(opts ...Option) (*options, error) {
169169
}
170170

171171
// Wrap the transport in something that can retry network flakes.
172-
o.transport = transport.NewRetry(o.transport, transport.WithRetryPredicate(predicate), transport.WithRetryStatusCodes(o.retryStatusCodes...))
173-
172+
o.transport = transport.NewRetry(o.transport, transport.WithRetryBackoff(o.retryBackoff), transport.WithRetryPredicate(predicate), transport.WithRetryStatusCodes(o.retryStatusCodes...))
174173
// Wrap this last to prevent transport.New from double-wrapping.
175174
if o.userAgent != "" {
176175
o.transport = transport.NewUserAgent(o.transport, o.userAgent)

0 commit comments

Comments
 (0)