Skip to content

Commit

Permalink
fix: Fix the crane release url and add more steps (#1532)
Browse files Browse the repository at this point in the history
  • Loading branch information
okozachenko1203 committed Feb 3, 2023
1 parent 824efc7 commit e04520b
Showing 1 changed file with 12 additions and 4 deletions.
16 changes: 12 additions & 4 deletions cmd/crane/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,9 @@ A collection of useful things you can do with `crane` is [here](recipes.md).
## Installation

### Install from Releases
Download [latest release](https://github.com/google/go-containerregistry/releases/latest):
```
1. Download [latest release](https://github.com/google/go-containerregistry/releases/latest):

```sh
$ OS=Linux # or Darwin, Windows
$ ARCH=x86_64 # or arm64, x86_64, armv6, i386, s390x
$ curl -sL "https://github.com/google/go-containerregistry/releases/latest/download/go-containerregistry_${OS}_${ARCH}.tar.gz" > go-containerregistry.tar.gz
Expand All @@ -25,18 +26,25 @@ $ ARCH=x86_64 # or arm64, x86_64, armv6, i386, s390x
$ curl -sL "https://github.com/google/go-containerregistry/releases/download/v${VERSION}/go-containerregistry_${OS}_${ARCH}.tar.gz" > go-containerregistry.tar.gz
```

2. Verify the signature
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:

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

3. Unpack it in the PATH.

```sh
$ tar -zxvf go-containerregistry.tar.gz -C /usr/local/bin/ crane
```

### Install manually
Install manually:

```
```sh
go install github.com/google/go-containerregistry/cmd/crane@latest
```

Expand Down

0 comments on commit e04520b

Please sign in to comment.