Skip to content

Commit

Permalink
krew support
Browse files Browse the repository at this point in the history
  • Loading branch information
tuxtof committed Jun 16, 2021
1 parent 872f147 commit 6f07d24
Show file tree
Hide file tree
Showing 3 changed files with 67 additions and 8 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,5 +24,5 @@ jobs:
args: release --rm-dist
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# - name: Update new version in krew-index
# uses: rajatjindal/[email protected]
- name: Update new version in krew-index
uses: rajatjindal/[email protected]
42 changes: 42 additions & 0 deletions .krew.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
apiVersion: krew.googlecontainertools.github.com/v1alpha2
kind: Plugin
metadata:
name: karbon
spec:
version: {{ .TagName }}
homepage: https://github.com/nutanix/kubectl-karbon
platforms:
- selector:
matchLabels:
os: darwin
arch: amd64
{{addURIAndSha "https://github.com/nutanix/kubectl-karbon/releases/download/{{ .TagName }}/kubectl-karbon_{{ .TagName }}_darwin_amd64.tar.gz" .TagName }}
bin: kubectl-karbon
- selector:
matchLabels:
os: darwin
arch: arm64
{{addURIAndSha "https://github.com/nutanix/kubectl-karbon/releases/download/{{ .TagName }}/kubectl-karbon_{{ .TagName }}_darwin_arm64.tar.gz" .TagName }}
bin: kubectl-karbon
- selector:
matchLabels:
os: linux
arch: amd64
{{addURIAndSha "https://github.com/nutanix/kubectl-karbon/releases/download/{{ .TagName }}/kubectl-karbon_{{ .TagName }}_linux_amd64.tar.gz" .TagName }}
bin: kubectl-karbon
- selector:
matchLabels:
os: linux
arch: arm64
{{addURIAndSha "https://github.com/nutanix/kubectl-karbon/releases/download/{{ .TagName }}/kubectl-karbon_{{ .TagName }}_linux_arm64.tar.gz" .TagName }}
bin: kubectl-karbon
- selector:
matchLabels:
os: windows
arch: amd64
{{addURIAndSha "https://github.com/nutanix/kubectl-karbon/releases/download/{{ .TagName }}/kubectl-karbon_{{ .TagName }}_windows_amd64.tar.gz" .TagName }}
bin: kubectl-karbon.exe
shortDescription: Connect to Nutanix Karbon cluster
description: |
This plugin allow to quickly connect to an existing Nutanix karbon cluster without the need to connect to Prism UI.
Read more documentation at: https://github.com/nutanix/kubectl-karbon
29 changes: 23 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@


## kubectl-karbon - Quickly connect to your Karbon cluster!

This kubectl extension allow to quickly connect to an existing karbon cluster without the need to connect to Prism UI.
Expand All @@ -11,27 +9,46 @@ https://user-images.githubusercontent.com/180613/117446386-4d04f080-af3c-11eb-86

---

[![Go Report Card](https://goreportcard.com/badge/github.com/nutanix/kubectl-karbon)](https://goreportcard.com/report/github.com/nutanix/kubectl-karbon)
[![Go Report Card](https://goreportcard.com/badge/github.com/nutanix/kubectl-karbon)](https://goreportcard.com/report/github.com/nutanix/kubectl-karbon)
![CI](https://github.com/nutanix/kubectl-karbon/actions/workflows/ci.yml/badge.svg)
![Release](https://github.com/nutanix/kubectl-karbon/actions/workflows/release.yml/badge.svg)

[![release](https://img.shields.io/github/release-pre/nutanix/kubectl-karbon.svg)](https://github.com/nutanix/kubectl-karbon/releases)
[![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://github.com/mum4k/termdash/blob/master/LICENSE)
[![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://github.com/nutanix/kubectl-karbon/blob/master/LICENSE)
![Proudly written in Golang](https://img.shields.io/badge/written%20in-Golang-92d1e7.svg)
[![Releases](https://img.shields.io/github/downloads/nutanix/kubectl-karbon/total.svg)](https://github.com/nutanix/kubectl-karbon/releases)

---



## Install
## Installation

There are several installation options:

- As kubectl plugins
- Manual installation

### Kubectl Plugins

You can install and use [Krew](https://github.com/kubernetes-sigs/krew/) kubectl
plugin manager to get the `karbon` plugin .

```sh
kubectl krew install karbon
```

After installing, the tools will be available as `kubectl karbon`.

### Manual

- Download your corresponding [release](https://github.com/nutanix/kubectl-karbon/releases)
- Install the binary somewhere in your PATH (/usr/local/bin for example)
- use it with `kubectl karbon`

***MacOS X notes for security error***

once your binary installed launch the following command:
Depending of your OS settings when you install you binary manually we must launch the following command:
`xattr -r -d com.apple.quarantine /usr/local/bin/kubectl-karbon`

## Usage
Expand Down

0 comments on commit 6f07d24

Please sign in to comment.