Skip to content

Commit dc0cc8e

Browse files
authored
Link to new docs across our gh repo (#6448)
* Link to new docs * Remove broken link * Update ansible.md removing old links * Update k8s-pvc.ipynb * Update k8s-pvc.md
1 parent cc05d2b commit dc0cc8e

File tree

5 files changed

+138
-142
lines changed

5 files changed

+138
-142
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -78,8 +78,8 @@ make undeploy-k8s
7878

7979
## Documentation
8080

81-
[Seldon Core 2 docs](https://docs.seldon.io/projects/seldon-core/en/v2/)
81+
[Seldon Core 2 docs](https://docs.seldon.ai/seldon-core-2)
8282

8383
## License
8484

85-
[License](LICENSE)
85+
[License](LICENSE)

ansible/README.md

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -236,7 +236,4 @@ You may want to also remove cache resources used for the installation with
236236
rm -rf ~/.cache/seldon/
237237
```
238238

239-
```{note}
240239
If you used Ansible to install Seldon Core 2 and its ecosystem into K8s cluster other than Kind you need to manually remove all the components.
241-
Notes on how to remove Seldon Core 2 Helm installation itself you can find [here](https://docs.seldon.io/projects/seldon-core/en/v2/contents/getting-started/kubernetes-installation/helm.html#uninstall).
242-
```

docs-gb/getting-started/kubernetes-installation/ansible.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
{% hint style="warning" %}
44
**Warning**: The Ansible installation of a Seldon Core and associated ecosystem is meant for **dev/testing** purposes.
5-
For production use cases follow [Helm installation](https://docs.seldon.io/projects/seldon-core/en/v2/contents/getting-started/kubernetes-installation/helm.html).
5+
For production use cases follow [Helm installation](https://docs.seldon.ai/seldon-core-2/installation/production-environment).
66
{% endhint %}
77

88
## Installing Ansible
@@ -241,5 +241,4 @@ rm -rf ~/.cache/seldon/
241241

242242
{% hint style="info" %}
243243
If you used Ansible to install Seldon Core 2 and its ecosystem into K8s cluster other than Kind you need to manually remove all the components.
244-
Notes on how to remove Seldon Core 2 Helm installation itself you can find [here](https://docs.seldon.io/projects/seldon-core/en/v2/contents/getting-started/kubernetes-installation/helm.html#uninstall).
245244
{% endhint %}

samples/examples/k8s-pvc/k8s-pvc.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@
9696
"id": "32da65b2",
9797
"metadata": {},
9898
"source": [
99-
"[**Now you should finish the Seldon install following the docs.**](https://docs.seldon.io/projects/seldon-core/en/v2/contents/getting-started/index.html)"
99+
"[**Now you should finish the Seldon install following the docs.**](https://docs.seldon.ai/seldon-core-2/installation/production-environment)"
100100
]
101101
},
102102
{

samples/examples/k8s-pvc/k8s-pvc.md

Lines changed: 134 additions & 134 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,36 @@
1-
## Kubernetes PVC Example
2-
3-
4-
```python
5-
import os
6-
os.environ["NAMESPACE"] = "seldon-mesh"
7-
```
8-
9-
10-
```python
11-
MESH_IP=!kubectl get svc seldon-mesh -n ${NAMESPACE} -o jsonpath='{.status.loadBalancer.ingress[0].ip}'
12-
MESH_IP=MESH_IP[0]
13-
import os
14-
os.environ['MESH_IP'] = MESH_IP
15-
MESH_IP
16-
```
17-
18-
19-
20-
21-
'172.19.255.1'
22-
23-
24-
25-
### Kind cluster setup
26-
27-
To run this example in Kind we need to start Kind with access to a local folder where are models are location. In this example we will use a folder in `/tmp` and associate that with a path in the container.
28-
29-
30-
```python
31-
!cat kind-config.yaml
32-
```
33-
1+
## Kubernetes PVC Example
2+
3+
4+
```python
5+
import os
6+
os.environ["NAMESPACE"] = "seldon-mesh"
7+
```
8+
9+
10+
```python
11+
MESH_IP=!kubectl get svc seldon-mesh -n ${NAMESPACE} -o jsonpath='{.status.loadBalancer.ingress[0].ip}'
12+
MESH_IP=MESH_IP[0]
13+
import os
14+
os.environ['MESH_IP'] = MESH_IP
15+
MESH_IP
16+
```
17+
18+
19+
20+
21+
'172.19.255.1'
22+
23+
24+
25+
### Kind cluster setup
26+
27+
To run this example in Kind we need to start Kind with access to a local folder where are models are location. In this example we will use a folder in `/tmp` and associate that with a path in the container.
28+
29+
30+
```python
31+
!cat kind-config.yaml
32+
```
33+
3434
apiVersion: kind.x-k8s.io/v1alpha4
3535
kind: Cluster
3636
nodes:
@@ -39,33 +39,33 @@ To run this example in Kind we need to start Kind with access to a local folder
3939
- hostPath: /tmp/models
4040
containerPath: /models
4141

42-
43-
44-
To start a Kind cluster with these settings using our ansible script you can run from the project root folder
45-
46-
```
47-
ansible-playbook ansible/playbooks/kind-cluster.yaml -e kind_config_file=${PWD}/samples/examples/local-pvc/kind-config.yaml
48-
```
49-
50-
[**Now you should finish the Seldon install following the docs.**](https://docs.seldon.io/projects/seldon-core/en/v2/contents/getting-started/index.html)
51-
52-
Create the local folder we will use for our models and copy an example iris sklearn model to it.
53-
54-
55-
```python
56-
!mkdir -p /tmp/models
57-
!gsutil cp -r gs://seldon-models/mlserver/iris /tmp/models
58-
```
59-
60-
### Create Server with PVC
61-
62-
Here we create a storage class and associated persistent colume referencing the `/models` folder where our models are stored.
63-
64-
65-
```python
66-
!cat pvc.yaml
67-
```
68-
42+
43+
44+
To start a Kind cluster with these settings using our ansible script you can run from the project root folder
45+
46+
```
47+
ansible-playbook ansible/playbooks/kind-cluster.yaml -e kind_config_file=${PWD}/samples/examples/local-pvc/kind-config.yaml
48+
```
49+
50+
[**Now you should finish the Seldon install following the docs.**](https://docs.seldon.ai/seldon-core-2/installation/production-environment)
51+
52+
Create the local folder we will use for our models and copy an example iris sklearn model to it.
53+
54+
55+
```python
56+
!mkdir -p /tmp/models
57+
!gsutil cp -r gs://seldon-models/mlserver/iris /tmp/models
58+
```
59+
60+
### Create Server with PVC
61+
62+
Here we create a storage class and associated persistent colume referencing the `/models` folder where our models are stored.
63+
64+
65+
```python
66+
!cat pvc.yaml
67+
```
68+
6969
apiVersion: storage.k8s.io/v1
7070
kind: StorageClass
7171
metadata:
@@ -107,17 +107,17 @@ Here we create a storage class and associated persistent colume referencing the
107107
selector:
108108
matchLabels:
109109
type: local
110-
111-
112-
Now we create a new Server based on the provided MLServer configuration but extend it with our PVC by adding this to the rclone container which will allow rclone to move models from this PVC onto the server.
113-
114-
We also add a new capability `pvc` to allow us to schedule models to this server that has the PVC.
115-
116-
117-
```python
118-
!cat server.yaml
119-
```
120-
110+
111+
112+
Now we create a new Server based on the provided MLServer configuration but extend it with our PVC by adding this to the rclone container which will allow rclone to move models from this PVC onto the server.
113+
114+
We also add a new capability `pvc` to allow us to schedule models to this server that has the PVC.
115+
116+
117+
```python
118+
!cat server.yaml
119+
```
120+
121121
apiVersion: mlops.seldon.io/v1alpha1
122122
kind: Server
123123
metadata:
@@ -136,17 +136,17 @@ We also add a new capability `pvc` to allow us to schedule models to this server
136136
volumeMounts:
137137
- name: models-pvc
138138
mountPath: /var/models
139-
140-
141-
### SKLearn Model
142-
143-
We use a simple sklearn iris classification model with the added `pvc` requirement so our MLServer with the PVC will be targeted during scheduling.
144-
145-
146-
```python
147-
!cat ./iris.yaml
148-
```
149-
139+
140+
141+
### SKLearn Model
142+
143+
We use a simple sklearn iris classification model with the added `pvc` requirement so our MLServer with the PVC will be targeted during scheduling.
144+
145+
146+
```python
147+
!cat ./iris.yaml
148+
```
149+
150150
apiVersion: mlops.seldon.io/v1alpha1
151151
kind: Model
152152
metadata:
@@ -156,29 +156,29 @@ We use a simple sklearn iris classification model with the added `pvc` requireme
156156
requirements:
157157
- sklearn
158158
- pvc
159-
160-
161-
162-
```python
163-
!kubectl create -f iris.yaml -n ${NAMESPACE}
164-
```
165-
159+
160+
161+
162+
```python
163+
!kubectl create -f iris.yaml -n ${NAMESPACE}
164+
```
165+
166166
model.mlops.seldon.io/iris created
167-
168-
169-
170-
```python
171-
!kubectl wait --for condition=ready --timeout=300s model --all -n ${NAMESPACE}
172-
```
173-
167+
168+
169+
170+
```python
171+
!kubectl wait --for condition=ready --timeout=300s model --all -n ${NAMESPACE}
172+
```
173+
174174
model.mlops.seldon.io/iris condition met
175-
176-
177-
178-
```python
179-
!kubectl get model iris -n ${NAMESPACE} -o jsonpath='{.status}' | jq -M .
180-
```
181-
175+
176+
177+
178+
```python
179+
!kubectl get model iris -n ${NAMESPACE} -o jsonpath='{.status}' | jq -M .
180+
```
181+
182182
{
183183
"conditions": [
184184
{
@@ -194,14 +194,14 @@ We use a simple sklearn iris classification model with the added `pvc` requireme
194194
],
195195
"replicas": 1
196196
}
197-
198-
199-
200-
```python
201-
!seldon model infer iris --inference-host ${MESH_IP}:80 \
202-
'{"inputs": [{"name": "predict", "shape": [1, 4], "datatype": "FP32", "data": [[1, 2, 3, 4]]}]}'
203-
```
204-
197+
198+
199+
200+
```python
201+
!seldon model infer iris --inference-host ${MESH_IP}:80 \
202+
'{"inputs": [{"name": "predict", "shape": [1, 4], "datatype": "FP32", "data": [[1, 2, 3, 4]]}]}'
203+
```
204+
205205
{
206206
"model_name": "iris_1",
207207
"model_version": "1",
@@ -225,16 +225,16 @@ We use a simple sklearn iris classification model with the added `pvc` requireme
225225
}
226226
]
227227
}
228-
229-
230-
Do a gRPC inference call
231-
232-
233-
```python
234-
!seldon model infer iris --inference-mode grpc --inference-host ${MESH_IP}:80 \
235-
'{"model_name":"iris","inputs":[{"name":"input","contents":{"fp32_contents":[1,2,3,4]},"datatype":"FP32","shape":[1,4]}]}' | jq -M .
236-
```
237-
228+
229+
230+
Do a gRPC inference call
231+
232+
233+
```python
234+
!seldon model infer iris --inference-mode grpc --inference-host ${MESH_IP}:80 \
235+
'{"model_name":"iris","inputs":[{"name":"input","contents":{"fp32_contents":[1,2,3,4]},"datatype":"FP32","shape":[1,4]}]}' | jq -M .
236+
```
237+
238238
{
239239
"modelName": "iris_1",
240240
"modelVersion": "1",
@@ -254,17 +254,17 @@ Do a gRPC inference call
254254
}
255255
]
256256
}
257-
258-
259-
260-
```python
261-
!kubectl delete -f ./iris.yaml -n ${NAMESPACE}
262-
```
263-
257+
258+
259+
260+
```python
261+
!kubectl delete -f ./iris.yaml -n ${NAMESPACE}
262+
```
263+
264264
model.mlops.seldon.io "iris" deleted
265-
266-
267-
268-
```python
269-
270-
```
265+
266+
267+
268+
```python
269+
270+
```

0 commit comments

Comments
 (0)