Skip to content

Commit e04520b

Browse files
fix: Fix the crane release url and add more steps (#1532)
1 parent 824efc7 commit e04520b

File tree

1 file changed

+12
-4
lines changed

1 file changed

+12
-4
lines changed

cmd/crane/README.md

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,9 @@ A collection of useful things you can do with `crane` is [here](recipes.md).
1010
## Installation
1111

1212
### Install from Releases
13-
Download [latest release](https://github.com/google/go-containerregistry/releases/latest):
14-
```
13+
1. Download [latest release](https://github.com/google/go-containerregistry/releases/latest):
14+
15+
```sh
1516
$ OS=Linux # or Darwin, Windows
1617
$ ARCH=x86_64 # or arm64, x86_64, armv6, i386, s390x
1718
$ curl -sL "https://github.com/google/go-containerregistry/releases/latest/download/go-containerregistry_${OS}_${ARCH}.tar.gz" > go-containerregistry.tar.gz
@@ -25,18 +26,25 @@ $ ARCH=x86_64 # or arm64, x86_64, armv6, i386, s390x
2526
$ curl -sL "https://github.com/google/go-containerregistry/releases/download/v${VERSION}/go-containerregistry_${OS}_${ARCH}.tar.gz" > go-containerregistry.tar.gz
2627
```
2728

29+
2. Verify the signature
2830
We generate [SLSA 3 provenance](https://slsa.dev) using the OpenSSF's [slsa-framework/slsa-github-generator](https://github.com/slsa-framework/slsa-github-generator). To verify our release, install the verification tool from [slsa-framework/slsa-verifier#installation](https://github.com/slsa-framework/slsa-verifier#installation) and verify as follows:
2931

30-
```
32+
```sh
3133
$ curl -sL https://github.com/google/go-containerregistry/releases/download/v${VERSION}/attestation.intoto.jsonl > provenance.intoto.jsonl
3234
$ slsa-verifier -artifact-path go-containerregistry.tar.gz -provenance provenance.intoto.jsonl -source github.com/google/go-containerregistry -tag "v${VERSION}"
3335
PASSED: Verified SLSA provenance
3436
```
3537

38+
3. Unpack it in the PATH.
39+
40+
```sh
41+
$ tar -zxvf go-containerregistry.tar.gz -C /usr/local/bin/ crane
42+
```
43+
3644
### Install manually
3745
Install manually:
3846

39-
```
47+
```sh
4048
go install github.com/google/go-containerregistry/cmd/crane@latest
4149
```
4250

0 commit comments

Comments
 (0)