Skip to content

Commit 308a03b

Browse files
committed
Readme updated
1 parent 0dc89b5 commit 308a03b

File tree

1 file changed

+111
-2
lines changed

1 file changed

+111
-2
lines changed

README.md

Lines changed: 111 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,111 @@
1-
# powervs-csi-driver
2-
CSI Driver for IBM® Power Systems™ Virtual Server
1+
# IBM PowerVS Block CSI Driver
2+
CSI Driver for IBM® Power Systems™ Virtual Servers
3+
4+
# Overview
5+
The IBM Power Virtual Systems Container Storage Interface (CSI) Driver provides a CSI interface used by Container Orchestrators to manage the lifecycle of Power Virtual System volumes.
6+
7+
8+
# CSI Specification Compatibility Matrix
9+
| PowerVS CSI Driver \ CSI Version | v1.5.0 |
10+
| ----------------------------- | -------|
11+
| main branch | yes |
12+
13+
# Features
14+
The following CSI gRPC calls are implemented:
15+
16+
- **Controller Service:** CreateVolume, DeleteVolume, ControllerPublishVolume,ControllerUnpublishVolume, ControllerGetCapabilities, ValidateVolumeCapabilities
17+
- **Node Service:** NodeStageVolume, NodeUnstageVolume, NodePublishVolume, NodeUnpublishVolume, NodeGetCapabilities, NodeGetInfo
18+
- **Identity Service:** GetPluginInfo, GetPluginCapabilities
19+
20+
# CreateVolume Parameters
21+
There are several optional parameters that could be passed into ``` CreateVolumeRequest.parameters``` map, these parameters can be configured in StorageClass, see example:
22+
23+
| **Parameters** | **Values** | **Default** | **Description**|
24+
| ----------------------------- | ----------------------------- | ----------- | ----------------------------- |
25+
| "csi.storage.k8s.io/fstype" | xfs, ext2, ext3, ext4 | ext4 | File system type that will be formatted during volume creation. This parameter is case sensitive! |
26+
27+
28+
## Driver Options
29+
There are couple driver options that can be passed as arguments when starting driver container.
30+
31+
| Option argument | value sample | default | Description |
32+
|-----------------------------|---------------------------------------------------|-----------------------------------------------------|---------------------|
33+
| endpoint | tcp://127.0.0.1:10000/ | unix:///var/lib/csi/sockets/pluginproxy/csi.sock | added to all volumes, for checking if a given volume was already created so that ControllerPublish/CreateVolume is idempotent. |
34+
| volume-attach-limit | 1,2,3 ... | -1 | Value for the maximum number of volumes attachable per node. If specified, the limit applies to all nodes. If not specified, the value is approximated from the instance type. |
35+
| debug | true | false | if true, driver will enable the debug log level|
36+
37+
38+
# IBM PowerVS Block CSI Driver on Kubernetes
39+
Following sections are Kubernetes specific. If you are Kubernetes user, use followings for driver features, installation steps and examples.
40+
41+
## Kubernetes Version Compatibility Matrix
42+
| PowerVS CSI Driver \ Kubernetes Version| v1.22 |
43+
|----------------------------------------|-------|
44+
| main branch | yes |
45+
46+
## Features
47+
* **Static Provisioning** - create a new or migrating existing PowerVS volumes, then create persistence volume (PV) from the PowerVS volume and consume the PV from container using persistence volume claim (PVC).
48+
* **Dynamic Provisioning** - uses persistence volume claim (PVC) to request the Kuberenetes to create the PowerVS volume on behalf of user and consumes the volume from inside container.
49+
* **Mount Option** - mount options could be specified in persistence volume (PV) to define how the volume should be mounted.
50+
* **[Volume Resizing](https://kubernetes-csi.github.io/docs/volume-expansion.html)** - expand the volume size. The corresponding CSI feature (`ExpandCSIVolumes`) is beta since Kubernetes 1.16.
51+
52+
## Prerequisites
53+
* If you are managing PowerVS volumes using static provisioning, get yourself familiar with [Power Virtual Servers](https://cloud.ibm.com/docs/power-iaas?topic=power-iaas-getting-started).
54+
* Get yourself familiar with how to setup Kubernetes on IBM Cloud and have a working Kubernetes cluster:
55+
* Enable flag `--allow-privileged=true` for `kubelet` and `kube-apiserver`
56+
* Enable `kube-apiserver` feature gates `--feature-gates=CSINodeInfo=true,CSIDriverRegistry=true,CSIBlockVolume=true`
57+
* Enable `kubelet` feature gates `--feature-gates=CSINodeInfo=true,CSIDriverRegistry=true,CSIBlockVolume=true`
58+
59+
60+
## Installation
61+
#### Set up driver permission
62+
63+
* Using secret object - Generate IBMCLOUD_APIKEY from the UI, put that user's credentials in [secret manifest](../deploy/kubernetes/secret.yaml), then deploy the secret
64+
```sh
65+
curl https://raw.githubusercontent.com/kubernetes-sigs/ibm-powervs-block-csi-driver/blob/main/deploy/kubernetes/secret.yaml > secret.yaml
66+
# Edit the IBMCLOUD_API_KEY
67+
# Edit the secret with user credentials
68+
kubectl apply -f secret.yaml
69+
```
70+
71+
#### Deploy driver
72+
Please see the compatibility matrix above before you deploy the driver
73+
74+
To deploy the CSI driver:
75+
```sh
76+
kubectl apply -k "https://github.com/kubernetes-sigs/ibm-powervs-block-csi-driver/deploy/kubernetes/overlays/stable"
77+
```
78+
79+
Verify driver is running:
80+
```sh
81+
kubectl get pods -n kube-system
82+
```
83+
84+
#### Deploy driver with debug mode
85+
To view driver debug logs, run the CSI driver with `-v=5` command line option
86+
87+
To enable powervs debug logs, run the CSI driver with `debug=true` command line option.
88+
89+
## Examples
90+
Make sure you follow the [Prerequisites](README.md#Prerequisites) before the examples:
91+
* [Dynamic Provisioning](../examples/kubernetes/dynamic-provisioning)
92+
* [Block Volume](../examples/kubernetes/block-volume)
93+
* [Configure StorageClass](../examples/kubernetes/storageclass)
94+
* [Volume Resizing](../examples/kubernetes/resizing)
95+
96+
97+
## Development
98+
Please go through [CSI Spec](https://github.com/container-storage-interface/spec/blob/master/spec.md) and [General CSI driver development guideline](https://kubernetes-csi.github.io/docs/developing.html) to get some basic understanding of CSI driver before you start.
99+
100+
### Requirements
101+
* Golang 1.17.+
102+
* [Ginkgo](https://github.com/onsi/ginkgo) in your PATH for integration testing and end-to-end testing
103+
* Docker 20.10+ for releasing
104+
105+
### Dependency
106+
Dependencies are managed through go module. To build the project, first turn on go mod using `export GO111MODULE=on`, then build the project using: `make`
107+
108+
### Testing
109+
* To create binary, run: `make bin/ibm-powervs-block-csi-driver`
110+
* To build image, run: `make image`
111+
* To push image, run: `make push`

0 commit comments

Comments
 (0)