Skip to content

Commit

Permalink
update helm packaging and README for helm installs
Browse files Browse the repository at this point in the history
  • Loading branch information
eljohnson92 committed Feb 21, 2024
1 parent 97c2453 commit d7441e6
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 24 deletions.
15 changes: 6 additions & 9 deletions .github/workflows/helm.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,11 @@
name: Helm

on:
push:
branches:
- main
paths:
- 'helm-chart/**'
pull_request:
paths:
- 'helm-chart/**'
workflow_dispatch: {}
release: {}

permissions:
contents: read
Expand All @@ -26,8 +22,8 @@ jobs:
- name: Set Version
run: |
TAG=$(git describe --tags --abbrev=0)
sed -ie "s/appVersion: \"latest\"/appVersion: ${TAG#v}/g" ./helm-chart/csi-driver/Chart.yaml
sed -ie "s/version: 0.0.0/version: ${TAG#v}/g" ./helm-chart/csi-driver/Chart.yaml
sed -ie "s/appVersion: \"latest\"/appVersion: ${TAG#helm-}/g" ./helm-chart/csi-driver/Chart.yaml
sed -ie "s/version: 0.0.0/version: ${TAG#helm-}/g" ./helm-chart/csi-driver/Chart.yaml
- name: Set up Helm
uses: azure/setup-helm@v3
Expand Down Expand Up @@ -65,8 +61,8 @@ jobs:
- name: Set Version
run: |
TAG=$(git describe --tags --abbrev=0)
sed -ie "s/appVersion: \"latest\"/appVersion: ${TAG#v}/g" ./helm-chart/csi-driver/Chart.yaml
sed -ie "s/version: 0.0.0/version: ${TAG#v}/g" ./helm-chart/csi-driver/Chart.yaml
sed -ie "s/appVersion: \"latest\"/appVersion: ${TAG#helm-}/g" ./helm-chart/csi-driver/Chart.yaml
sed -ie "s/version: 0.0.0/version: ${TAG#helm-}/g" ./helm-chart/csi-driver/Chart.yaml
- name: Configure Git
run: |
Expand All @@ -80,6 +76,7 @@ jobs:
uses: helm/chart-releaser-action@v1.6.0
env:
CR_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
CR_RELEASE_NAME_TEMPLATE: "helm-{{ .Version }}"
with:
charts_dir: helm-chart
skip_existing: true
30 changes: 15 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
# Linode Block Storage CSI Driver [![Test](https://github.com/linode/linode-blockstorage-csi-driver/actions/workflows/test.yml/badge.svg?branch=master)](https://github.com/linode/linode-blockstorage-csi-driver/actions/workflows/test.yml) [![Docker build](https://github.com/linode/linode-blockstorage-csi-driver/actions/workflows/docker-hub.yml/badge.svg?branch=master)](https://github.com/linode/linode-blockstorage-csi-driver/actions/workflows/docker-hub.yml)
# Linode Block Storage CSI Driver
[![Test](https://github.com/linode/linode-blockstorage-csi-driver/actions/workflows/test.yml/badge.svg?branch=master)](https://github.com/linode/linode-blockstorage-csi-driver/actions/workflows/test.yml) [![Docker build](https://github.com/linode/linode-blockstorage-csi-driver/actions/workflows/docker-hub.yml/badge.svg?branch=master)](https://github.com/linode/linode-blockstorage-csi-driver/actions/workflows/docker-hub.yml)

## Overview
The Container Storage Interface ([CSI](https://github.com/container-storage-interface/spec)) Driver for Linode Block Storage enables container orchestrators such as Kubernetes to manage the life-cycle of persistent storage claims.
Expand All @@ -25,38 +26,37 @@ This token will need:
* A sufficient "Expiry" to allow for continued use of your volumes

### [Recommended] Using Helm to deploy the CSI Driver
LINODE_API_TOKEN must be a Linode APIv4 [Personal Access Token](https://cloud.linode.com/profile/tokens) with Volume and Linode permissions.

Use the helm chart located under './helm-chart/csi-driver'. This dir has the manifest for Linode Block Storage CSI Driver.
REGION must be a Linode [region](https://api.linode.com/v4/regions).

#### To deploy the CSI Driver from the release artifact
#### Install the csi-linode repo
```shell
helm repo add linode-csi https://linode.github.io/linode-blockstorage-csi-driver/
helm repo update linode-csi
```

#### To deploy the CSI Driver
```sh
export VERSION=v0.6.0
export LINODE_API_TOKEN=<linodeapitoken>
export REGION=<linoderegion>

helm install linode-csi-driver --set apiToken=$LINODE_API_TOKEN,region=$REGION https://github.com/linode/linode-blockstorage-csi-driver/releases/download/$VERSION/helm-chart-$VERSION.tgz
helm install linode-csi-driver --set apiToken=$LINODE_API_TOKEN,region=$REGION linode-csi/linode-blockstorage-csi-driver
```
_See [helm install](https://helm.sh/docs/helm/helm_install/) for command documentation._

#### Uninstall

To uninstall linode-csi-driver from kubernetes cluster, run the following command:

#### To uninstall linode-csi-driver from kubernetes cluster. Run the following command:
```sh
helm uninstall linode-csi-driver
```
_See [helm uninstall](https://helm.sh/docs/helm/helm_uninstall/) for command documentation._

#### Upgrade

To upgrade when new changes are made to the helm chart, run the following command:

#### To upgrade when new changes are made to the helm chart. Run the following command:
```sh
export VERSION=v0.6.0
export LINODE_API_TOKEN=<linodeapitoken>
export REGION=<linoderegion>

helm upgrade linode-csi-driver --install --set apiToken=$LINODE_API_TOKEN,region=$REGION https://github.com/linode/linode-blockstorage-csi-driver/releases/download/$VERSION/helm-chart-$VERSION.tgz
helm upgrade linode-csi-driver --install --set apiToken=$LINODE_API_TOKEN,region=$REGION linode-csi/linode-blockstorage-csi-driver
```
_See [helm upgrade](https://helm.sh/docs/helm/helm_upgrade/) for command documentation._

Expand Down

0 comments on commit d7441e6

Please sign in to comment.