Skip to content

Commit a069713

Browse files
authored
Added documentation for git support in storage initializer. (#581)
* Added documentation for git support in storage initializer. Signed-off-by: Horvath Agoston <horvath.agoston@gmail.com> * Added forgotten references to git storage. Signed-off-by: Horvath Agoston <horvath.agoston@gmail.com> --------- Signed-off-by: Horvath Agoston <horvath.agoston@gmail.com>
1 parent 31995fc commit a069713

3 files changed

Lines changed: 42 additions & 0 deletions

File tree

docs/model-serving/storage/overview.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ KServe can serve models from various storage locations, including:
2525

2626
### Other Storage Options
2727
- **[URI/HTTP(S)](./providers/uri.md)** - Serve models from HTTP or HTTPS URIs.
28+
- **[Git](./providers/git.md)** - Serve models from git repositories.
2829
- **[Persistent Volume Claims (PVC)](./providers/pvc.md)** - Use Kubernetes PVCs to store and serve models.
2930
- **[Hugging Face](./providers/hf.md)** - Directly serve models from the Hugging Face model hub.
3031
- **[OCI Images](./providers/oci.md)** - Package and serve models as OCI container images using Modelcars.
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
---
2+
title: Git
3+
description: Deploy models to KServe InferenceService from git repository.
4+
---
5+
6+
# Deploy InferenceService with a saved model from a URI
7+
8+
Git download supports https protocol only and no branches.
9+
10+
To use it, specify the model url in the following format: `https://github.com/kserve/kserve.git`
11+
12+
Specify username via either the environment variables `GIT_USERNAME`, or directly in the URL: `https://username@github.com/kserve/kserve.git`. When both present, username from URL takes precedence.
13+
14+
Specify password via the `GIT_PASSWORD` environment variable. Note that password via URL will be ignored.
15+
16+
17+
# Password considerations
18+
19+
You should keep the password in a k8s `Secret`, e.g.:
20+
21+
```bash
22+
kubectl create secret generic git-secret --from-literal=GIT_PASSWORD='yolo'
23+
```
24+
25+
Which you can refer to like this:
26+
27+
```yaml
28+
apiVersion: serving.kserve.io/v1beta1
29+
kind: InferenceService
30+
spec:
31+
predictor:
32+
model:
33+
env:
34+
- name: GIT_PASSWORD
35+
valueFrom:
36+
secretKeyRef:
37+
name: git-secret
38+
key: GIT_PASSWORD
39+
optional: false
40+
```

sidebars.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -286,6 +286,7 @@ const sidebars: SidebarsConfig = {
286286
'model-serving/storage/providers/azure',
287287
'model-serving/storage/providers/s3/s3',
288288
'model-serving/storage/providers/gcs',
289+
'model-serving/storage/providers/git',
289290
'model-serving/storage/providers/uri',
290291
'model-serving/storage/providers/pvc',
291292
'model-serving/storage/providers/oci',

0 commit comments

Comments
 (0)