Skip to content

Commit 97cad2c

Browse files
authored
Merge pull request #65 from kube-HPC/update_volumes_info
updated volume section for sidecar
2 parents 94f56aa + f74c696 commit 97cad2c

File tree

2 files changed

+22
-30
lines changed

2 files changed

+22
-30
lines changed

site/learn/API.md

Lines changed: 7 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ sublinks: Restful, Cli
88
next: /learn/algorithms/
99
---
1010

11-
HKube support two types of APIs, Restful and Cli
11+
HKube supports two types of APIs, Restful and Cli.
1212

1313
### Restful API
1414

@@ -18,28 +18,18 @@ Also check the [Swagger-UI](http://petstore.swagger.io/?url=https://raw.githubus
1818

1919
### Cli
2020

21-
`hkubectl` is a command-line tool that help you to work with hkube more easily.
22-
23-
24-
#### Download
25-
26-
```console
27-
export latestVersion="$(curl -s https://api.github.com/repos/kube-HPC/hkubectl/releases/latest | grep -oP '"tag_name": "\K(.*)(?=")')"
28-
curl -Lo hkubectl https://github.com/kube-HPC/hkubectl/releases/download/${latestVersion}/hkubectl-linux \
29-
&& chmod +x hkubectl \
30-
&& sudo mv hkubectl /usr/local/bin/
31-
```
32-
33-
#### Config
34-
35-
`hkubectl` config set endpoint <KUBERNETES-MASTER-IP>
36-
`hkubectl` config set rejectUnauthorized false
21+
`hkubectl` is a command-line tool that help you to work with hkube more easily.
22+
For download, please follow the instructions [here](../installCLI/#setup).
3723

3824
#### Syntax
3925

4026
```
4127
hkubectl [type] [command] [name]
4228
```
29+
To get commands and options, run:
30+
```
31+
hkubectl --help
32+
```
4333

4434

4535
In the next sections you will learn in details about the pipeline definitions.

site/learn/Sidecars.md

Lines changed: 15 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -35,12 +35,6 @@ Below is an example of a complete sidecar configuration:
3535
}
3636
}
3737
},
38-
"volumes": [
39-
{
40-
"name": "shared-volume",
41-
"emptyDir": {}
42-
}
43-
],
4438
"volumeMounts": [
4539
{
4640
"name": "shared-volume",
@@ -91,23 +85,31 @@ Below is an example of a sidecar container configuration, with resources:
9185
> **Note:** Resources are not mandatory and will default to a preset value if not provided. You can change the default values by modifying `config.resources`.
9286
9387
## Volumes Usage
94-
Sidecars can mount volumes for shared storage. In HKube, `volumes` are defined in the volumes section and mounted using `volumeMounts`.
88+
Sidecars can mount volumes for shared storage. In HKube, `volumes` are defined in the volumes section at the algorithm level, and mounted using `volumeMounts` in the sidecar or algorithm (for algorunner) level.
9589

9690
**Example:**
9791
```json
9892
{
93+
"name": "algo-car-with-volume-mount",
94+
"algorithmImage": "docker.io/hkubedevtest/print-every-10-sec:v4o4c4xne",
95+
"volumes": [
96+
{
97+
"name": "shared-volume",
98+
"emptyDir": {}
99+
}
100+
],
101+
"volumeMounts": [
102+
{
103+
"name": "shared-volume",
104+
"mountPath": "/shared-dir"
105+
}
106+
],
99107
"sideCars": [
100108
{
101109
"container": {
102110
"name": "mycar",
103111
"image": "httpd"
104112
},
105-
"volumes": [
106-
{
107-
"name": "shared-volume",
108-
"emptyDir": {}
109-
}
110-
],
111113
"volumeMounts": [
112114
{
113115
"name": "shared-volume",

0 commit comments

Comments
 (0)