Skip to content

Commit

Permalink
updates markdown to include binary instructions
Browse files Browse the repository at this point in the history
  • Loading branch information
joshbrgs committed Oct 25, 2023
1 parent 9926403 commit acd9e32
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 6 deletions.
4 changes: 2 additions & 2 deletions site/content/docs/developer-guide/distributing-with-krew.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ without having to deal with their package managers.
Once you [develop]({{< ref "develop/plugin-development.md" >}}) a `kubectl`
plugin, follow these steps to distribute your plugin on Krew:

1. Package your plugin into an archive file (`.tar.gz` or `.zip`).
1. Make the archive file publicly available (e.g. as GitHub release files).
1. Package your plugin into an archive file or binary (`.bin`, `.tar.gz` or `.zip`).
1. Make them publicly available (e.g. as GitHub release files).
1. Write a [Krew plugin manifest]({{< ref "plugin-manifest.md" >}}) file.
1. [Submit your plugin to krew-index]({{< ref "release/../release/submitting-to-krew.md" >}}).
4 changes: 2 additions & 2 deletions site/content/docs/developer-guide/installing-locally.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ weight: 300
---

After you have written your [plugin manifest]({{< ref "plugin-manifest.md" >}})
and archived your plugin into a `.zip` or `.tar.gz` file, you can verify that
and archived your plugin into a `.zip` or `.tar.gz` or a raw binary file, you can verify that
your plugin installs correctly with Krew by running:

```sh
Expand All @@ -15,7 +15,7 @@ your plugin installs correctly with Krew by running:
- The `--manifest` flag specifies a custom manifest rather than using
the default [krew index][index]
- `--archive` overrides the download `uri:` specified in the plugin manifest and
uses a local `.zip` or `.tar.gz` file instead.
uses a local `.bin`, `.zip` or `.tar.gz` file instead.

If the installation **fails**, run the command again with `-v=4` flag to see the
verbose logs and examine what went wrong.
Expand Down
14 changes: 12 additions & 2 deletions site/content/docs/developer-guide/plugin-manifest.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,10 +81,10 @@ spec:

## Specifying plugin download options

Krew plugins must be packaged as `.zip` or `.tar.gz` archives, and should be
Krew plugins must be packaged as `.zip` or `.tar.gz` archives, or as a binary, and should be
accessible to download from a user’s machine. The relevant fields are:

- `uri`: URL to the archive file (`.zip` or `.tar.gz`)
- `uri`: URL to the archive file (`.zip`, `.bin` or `.tar.gz`)
- `sha256`: sha256 sum of the archive file

```yaml
Expand All @@ -94,6 +94,16 @@ accessible to download from a user’s machine. The relevant fields are:
...
```

If you are specifying a binary, you will have the option to also specify a license that krew
will install with your binary

```yaml
platforms:
- uri: https://github.com/foo/bar/archive/v1.2.3.zip
sha256: "29C9C411AF879AB85049344B81B8E8A9FBC1D657D493694E2783A2D0DB240775"
license: https://raw.githubusercontent.com/foo/bar/v1.0.1/LICENSE
```

## Specifying platform-specific instructions

Krew makes it possible to install the same plugin on different operating systems
Expand Down

0 comments on commit acd9e32

Please sign in to comment.