Skip to content

Commit b7f6965

Browse files
authored
Merge pull request #48 from moshe010/ssl_docs
Ssl docs
2 parents 1c9c6cb + 95c9da4 commit b7f6965

File tree

2 files changed

+123
-25
lines changed

2 files changed

+123
-25
lines changed

README.md

Lines changed: 122 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@
1010
* [Building Subnet Manager Plugins](#building-subnet-manager-plugins)
1111
* [Building Container Image](#building-container-image)
1212
* [Configuration Reference](#configuration-reference)
13+
* [Plugins](#plugins)
14+
* [NOOP Plugin](#noop-plugin)
15+
* [UFM (Unified Fabric Manager) Plugin](#ufm-plugin)
1316
* [Deployment](#deployment)
1417

1518
# InfiniBand Kubernetes
@@ -18,11 +21,11 @@ InfiniBand Kubernetes provides a daemon `ib-kubernetes`, that works in conjuctio
1821

1922
## Subnet Manager Plugins
2023

21-
InifiBand Kubernets uses [Golang plugins](https://golang.org/pkg/plugin/) to add the guids to PKey subnet manager.
24+
InifiBand Kubernets uses [Golang plugins](https://golang.org/pkg/plugin/) to communicate with the fabric subnet manager
2225
Subnet manager plugins exists in `pkg/sm/plugins`. There are currently 2 plugins:
2326

24-
1. UFM Plugin: This plugin communicate with [Mellanox UFM ](https://www.mellanox.com/products/management-software/ufm) rest api to add the Generated Guids to PKey.
25-
2. Noop Plugin: This plugin doesn't do any special operations, it can be used as template for developing user's own plugin.
27+
1. UFM Plugin
28+
2. NOOP Plugin
2629

2730
## Build
2831

@@ -41,54 +44,148 @@ Upon successful build the binary will be available in `build/ib-kubernetes`.
4144

4245
To build all the plugins binaries for InfiniBand Kubernetes that exist in `pkg/sm/plugins`
4346

44-
```shell script
45-
# building all plugins
47+
#### Building all plugins
48+
```
4649
$ make plugins
50+
```
4751

48-
# building one plugin, make <plugin-name>-plugin
49-
$ make noop-plugin
52+
#### Building a specific plugin
53+
```
54+
make <plugin name>-plugin
55+
```
56+
Example:
57+
```
58+
$ make ufm-plugin
5059
```
5160
Upon successful build the plugins binaries will be available in `build/plugins/`.
5261

53-
Note: to build all binaries at once run `$ make`.
62+
Note: to build all binaries at once run `make`.
5463

5564
### Building Container Image
5665

5766
To build container image
5867

59-
```shell script
60-
# Building image mellanox/ib-kubernetes
68+
#### Building image mellanox/ib-kubernetes
69+
```
6170
$ make image
71+
```
6272

63-
# Building image with custom tag and Dockerfile
73+
#### Building image with custom tag and Dockerfile
74+
```
6475
$ DOCKERFILE=myfile TAG=mytag make image
6576
```
6677

6778
## Configuration Reference
6879

69-
User can provide the following configurations as environment variables or for the ConfigMap :
70-
* `DAEMON_SM_PLUGIN`: Name of the subnet manager plugin. Currently supported `"noop"` and `"ufm"`.
71-
* `DAEMON_PERIODIC_UPDATE`: Interval in seconds to send add and remove request to subnet manager.
72-
* `GUID_POOL_RANGE_START`: The first guid in the pool e.g: `"02:00:00:00:00:00:00:00"`.
73-
* `GUID_POOL_RANGE_END`: The Last guid in the pool.
80+
IB Kubernetes configration as ConfigMap :
81+
```yaml
82+
apiVersion: v1
83+
kind: ConfigMap
84+
metadata:
85+
name: ib-kubernetes-config
86+
namespace: kube-system
87+
data:
88+
DAEMON_SM_PLUGIN: "ufm" # Name of the subnet manager plugin
89+
DAEMON_PERIODIC_UPDATE: "5" # Interval in seconds to send add and remove request to subnet manager
90+
GUID_POOL_RANGE_START: "02:00:00:00:00:00:00:00" # The first guid in the pool
91+
GUID_POOL_RANGE_END: "02:FF:FF:FF:FF:FF:FF:FF" # The last guid in the pool
92+
```
93+
94+
## Plugins
95+
96+
Subnet Manager Plugin to configure PKeys (Partition Keys) in the InfiniBand fabric.
7497
75-
**Configurations if "ufm" subnet manager plugin is used for `deployment/ib-kubernetes-ufm-secret.yaml`:**
76-
* `UFM_USERNAME`: Username of UFM.
77-
* `UFM_PASSWORD`: Password of UFM.
78-
* `UFM_ADDRESS`: IP address or hostname of UFM server.
79-
* `UFM_HTTP_SCHEMA`: http/https, default is https.
80-
* `UFM_PORT`: REST API port of UFM default is 443 (https), if `httpSchema` is set to http then the default is 80.
81-
* `UFM_CERTIFICATE`: Secure certificate if using secure connection.
98+
### NOOP Plugin
99+
100+
Plugin that does nothing. Example for developing user subnet manager plugin
101+
102+
### UFM (Unified Fabric Manager) Plugin
103+
104+
[UFM](https://www.mellanox.com/products/management-software/ufm) is a powerful platform for managing scale-out computing environments.
105+
UFM Plugin allow to configure PKeys (Partition Keys) via UFM.
106+
107+
#### Plugin Configuration
108+
109+
```yaml
110+
apiVersion: v1
111+
kind: Secret
112+
metadata:
113+
name: ib-kubernetes-ufm-secret
114+
namespace: kube-system
115+
stringData:
116+
UFM_USERNAME: "admin" # UFM Username
117+
UFM_PASSWORD: "123456" # UFM Password
118+
UFM_ADDRESS: "" # UFM Hostname/IP Address
119+
UFM_HTTP_SCHEMA: "" # http/https. Default: https
120+
UFM_PORT: "" # UFM REST API port. Defaults: 443(https), 80(http)
121+
string:
122+
UFM_CERTIFICATE: "" # UFM Certificate in base64 format. (if not provided client will not verify server's certificate chain and host name)
123+
```
124+
125+
#### UFM CERTIFICATE
126+
127+
UFM utilizes certificates to authenticate requests, during deployment you should provide UFM with a valid certificate
128+
in your organization or create a self signed one.
129+
130+
##### Self Signed Certificates
131+
132+
Optional step if don't have a valid certificate for UFM.
133+
134+
##### Login to UFM
135+
136+
Containerized UFM:
137+
```
138+
$ docker exec -it ufm bash
139+
```
140+
141+
##### Create private key and certificate
142+
```
143+
$ openssl req -x509 -newkey rsa:4096 -keyout ufm.key -out ufm.crt -days 365 -subj '/CN=<UFM hostname>'
144+
```
145+
146+
#### Install UFM private key and certificate
147+
148+
##### Login to UFM
149+
150+
Containerized UFM:
151+
```
152+
$ docker exec -it ufm bash
153+
```
154+
155+
##### Copy private and crtificate to UFM location
156+
```
157+
$ cp ufm.key /etc/pki/tls/private/ufmlocalhost.key
158+
$ cp ufm.crt /etc/pki/tls/certs/ufmlocalhost.crt
159+
160+
```
161+
162+
##### Restart UFM
163+
164+
Containerized UFM:
165+
```
166+
$ docker restart ufm
167+
```
168+
169+
Bare-metal UFM:
170+
```
171+
systemctl restart ufmd
172+
```
173+
174+
#### Create UFM secret
175+
```
176+
$ kubectl create secret generic ib-kubernetes-ufm-secret --namespace="kube-system" --from-literal=UFM_USER="admin" --from-literal=UFM_PASSWORD="12345" --from-literal=UFM_ADDRESS="127.0.01" --from-file=UFM_CERTIFICATE=ufmlocalhost.crt --dry-run -o yaml > ib-kubernetes-ufm-secret.yaml
177+
$ kubectl create -f ./ib-kubernetes-ufm-secret.yaml
178+
```
82179

83180
## Deployment
84181

85182
To deploy the InfiniBand Kbubernetes
86-
```shell script
183+
```
87184
$ kubectl create -f deployment/ib-kubernetes-configmap.yaml
88185
$ kubectl create -f deployment/ib-kubernetes-ufm-secret.yaml
89186
$ kubectl create -f deployment/ib-kubernetes.yaml
90187
```
91188

92189
## Limitations
93190

94-
- Each node in an Infiniband Kubernetes deployment may be associated with up to 128 PKeys due to kernel limitation.
191+
- Each node in an Infiniband Kubernetes deployment may be associated with up to 128 PKeys due to kernel limitation.

deployment/ib-kubernetes-ufm-secret.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,4 +9,5 @@ stringData:
99
UFM_ADDRESS: ""
1010
UFM_HTTP_SCHEMA: ""
1111
UFM_PORT: ""
12+
string:
1213
UFM_CERTIFICATE: ""

0 commit comments

Comments
 (0)