Skip to content

Commit f050976

Browse files
Add instruction for install Feast on IKS and OpenShift using Kustomize (#1534)
* Add instruction for install Feast on IKS using kustomize Signed-off-by: ted chang <htchang@us.ibm.com> * Apply suggestions from code review Co-authored-by: Animesh Singh <singhan@us.ibm.com> Co-authored-by: Animesh Singh <singhan@us.ibm.com>
1 parent 4591469 commit f050976

6 files changed

Lines changed: 80 additions & 56 deletions

File tree

CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,4 +121,4 @@ See the deployment guide of the respective cloud providers for how to work with
121121
- [Terraform Deployment on Amazon EKS](https://docs.feast.dev/feast-on-kubernetes/getting-started/install-feast/kubernetes-amazon-eks-with-terraform)
122122
- [Terraform Deployment on Azure AKS](https://docs.feast.dev/feast-on-kubernetes/getting-started/install-feast/kubernetes-azure-aks-with-terraform)
123123
- [Terraform Deployment on Google Cloud GKE](https://docs.feast.dev/feast-on-kubernetes/getting-started/install-feast/google-cloud-gke-with-terraform)
124-
- [Helm Deployment on IBM Cloud IKS](https://docs.feast.dev/feast-on-kubernetes/getting-started/install-feast/ibm-cloud-iks-with-helm)
124+
- [Kustomize Deployment on IBM Cloud IKS or OpenShift](https://docs.feast.dev/feast-on-kubernetes/getting-started/install-feast/ibm-cloud-iks-with-kustomize)

docs/SUMMARY.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
* [Azure AKS \(with Helm\)](feast-on-kubernetes/getting-started/install-feast/kubernetes-azure-aks-with-helm.md)
3939
* [Azure AKS \(with Terraform\)](feast-on-kubernetes/getting-started/install-feast/kubernetes-azure-aks-with-terraform.md)
4040
* [Google Cloud GKE \(with Terraform\)](feast-on-kubernetes/getting-started/install-feast/google-cloud-gke-with-terraform.md)
41-
* [IBM Cloud Kubernetes Service \(IKS\) \(with Helm\)](feast-on-kubernetes/getting-started/install-feast/ibm-cloud-iks-with-helm.md)
41+
* [IBM Cloud Kubernetes Service \(IKS\) and Red Hat OpenShift \(with Kustomize\)](feast-on-kubernetes/getting-started/install-feast/ibm-cloud-iks-with-kustomize.md)
4242
* [Connect to Feast](feast-on-kubernetes/getting-started/connect-to-feast/README.md)
4343
* [Python SDK](feast-on-kubernetes/getting-started/connect-to-feast/python-sdk.md)
4444
* [Feast CLI](feast-on-kubernetes/getting-started/connect-to-feast/feast-cli.md)

docs/feast-on-kubernetes/getting-started/install-feast/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,9 @@ This guide installs Feast into a Google Cloud environment using Terraform. The T
3232

3333
{% page-ref page="google-cloud-gke-with-terraform.md" %}
3434

35-
## IBM Cloud Kubernetes Service \(IKS\) \(using Helm\)
35+
## IBM Cloud Kubernetes Service \(IKS\) and Red Hat OpenShift \(using Kustomize\)
3636

37-
This guide installs Feast into an existing [IBM Cloud Kubernetes Service](https://www.ibm.com/cloud/kubernetes-service) using Helm.
37+
This guide installs Feast into an existing [IBM Cloud Kubernetes Service](https://www.ibm.com/cloud/kubernetes-service) or [Red Hat OpenShift on IBM Cloud](https://www.ibm.com/cloud/openshift) using Kustomize.
3838

39-
{% page-ref page="ibm-cloud-iks-with-helm.md" %}
39+
{% page-ref page="ibm-cloud-iks-with-kustomize.md" %}
4040

docs/getting-started/install-feast/ibm-cloud-iks-with-helm.md renamed to docs/feast-on-kubernetes/getting-started/install-feast/ibm-cloud-iks-with-kustomize.md

Lines changed: 36 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,28 @@
1-
# IBM Cloud Kubernetes Service \(IKS\) \(with Helm\)
1+
# IBM Cloud Kubernetes Service and Red Hat OpenShift \(with Kustomize\)
22

33
## Overview
44

5-
This guide installs Feast on an existing IBM Cloud Kubernetes cluster, and ensures the following services are running:
5+
This guide installs Feast on an existing IBM Cloud Kubernetes cluster or Red Hat OpenShift on IBM Cloud , and ensures the following services are running:
66

77
* Feast Core
88
* Feast Online Serving
99
* Postgres
1010
* Redis
11+
* Kafka \(Optional\)
1112
* Feast Jupyter \(Optional\)
1213
* Prometheus \(Optional\)
14+
15+
## 1. Prerequisites
1316

14-
## 1. Requirements
15-
16-
1. [IBM Cloud Kubernetes Service](https://www.ibm.com/cloud/kubernetes-service)
17-
2. Install [Kubectl](https://cloud.ibm.com/docs/containers?topic=containers-cs_cli_install#kubectl) that matches the major.minor versions of your IKS.
17+
1. [IBM Cloud Kubernetes Service](https://www.ibm.com/cloud/kubernetes-service) or [Red Hat OpenShift on IBM Cloud](https://www.ibm.com/cloud/openshift)
18+
2. Install [Kubectl](https://cloud.ibm.com/docs/containers?topic=containers-cs_cli_install#kubectl) that matches the major.minor versions of your IKS or Install the [OpenShift CLI](https://cloud.ibm.com/docs/openshift?topic=openshift-openshift-cli#cli_oc) that matches your local operating system and OpenShift cluster version.
1819
3. Install [Helm 3](https://helm.sh/)
20+
4. Install [Kustomize](https://kubectl.docs.kubernetes.io/installation/kustomize/)
21+
22+
## 2. Preparation
23+
### IBM Cloud Block Storage Setup (IKS only)
1924

20-
## 2. IBM Cloud Block Storage Setup
25+
:warning: If you have Red Hat OpenShift Cluster on IBM Cloud skip to this [section](#Security-Context-Constraint-Setup).
2126

2227
By default, IBM Cloud Kubernetes cluster uses [IBM Cloud File Storage](https://www.ibm.com/cloud/file-storage) based on NFS as the default storage class, and non-root users do not have write permission on the volume mount path for NFS-backed storage. Some common container images in Feast, such as Redis, Postgres, and Kafka specify a non-root user to access the mount path in the images. When containers are deployed using these images, the containers fail to start due to insufficient permissions of the non-root user creating folders on the mount path.
2328

@@ -79,39 +84,43 @@ Therefore, to deploy Feast we need to set up [IBM Cloud Block Storage](https://c
7984
```text
8085
ibmc-block-gold (default) ibm.io/ibmc-block 65s
8186
```
87+
### Security Context Constraint Setup (OpenShift only)
8288

83-
**3. Preparation**
84-
85-
Add the Feast Helm repository and download the latest charts:
89+
By default, in OpenShift, all pods or containers will use the [Restricted SCC](https://docs.openshift.com/container-platform/4.6/authentication/managing-security-context-constraints.html) which limits the UIDs pods can run with, causing the Feast installation to fail. To overcome this, you can allow Feast pods to run with any UID by executing the following:
8690

8791
```text
88-
helm repo add feast-charts https://feast-helm-charts.storage.googleapis.com
89-
helm repo update
92+
oc adm policy add-scc-to-user anyuid -z default,kf-feast-kafka -n feast
9093
```
94+
## 3. Installation
9195

92-
Feast includes a Helm chart that installs all necessary components to run Feast Core, Feast Online Serving, and an example Jupyter notebook.
93-
94-
Feast Core requires Postgres to run, which requires a secret to be set on Kubernetes:
96+
Install Feast using kustomize. The pods may take a few minutes to initialize.
9597

9698
```bash
97-
kubectl create secret generic feast-postgresql --from-literal=postgresql-password=password
99+
git clone https://github.com/kubeflow/manifests
100+
cd manifests/contrib/feast/
101+
kustomize build feast/base | kubectl apply -n feast -f -
98102
```
103+
### Optional: Enable Feast Jupyter and Kafka
99104

100-
## 4. Installation
101-
102-
Install Feast using Helm. The pods may take a few minutes to initialize.
105+
You may optionally enable the Feast Jupyter component which contains code examples to demonstrate Feast. Some examples require Kafka to stream real time features to the Feast online serving. To enable, edit the following properties in the `values.yaml` under the `manifests/contrib/feast` folder:
106+
```
107+
kafka.enabled: true
108+
feast-jupyter.enabled: true
109+
```
103110

104-
```bash
105-
helm install feast-release feast-charts/feast
111+
Then regenerate the resource manifests and deploy:
112+
```
113+
make feast/base
114+
kustomize build feast/base | kubectl apply -n feast -f -
106115
```
107116

108-
## 5. Use Jupyter to connect to Feast
117+
## 4. Use Feast Jupyter Notebook Server to connect to Feast
109118

110119
After all the pods are in a `RUNNING` state, port-forward to the Jupyter Notebook Server in the cluster:
111120

112121
```bash
113122
kubectl port-forward \
114-
$(kubectl get pod -l app=feast-jupyter -o custom-columns=:metadata.name) 8888:8888
123+
$(kubectl get pod -l app=feast-jupyter -o custom-columns=:metadata.name) 8888:8888 -n feast
115124
```
116125

117126
```text
@@ -123,6 +132,10 @@ You can now connect to the bundled Jupyter Notebook Server at `localhost:8888` a
123132

124133
{% embed url="http://localhost:8888/tree?" caption="" %}
125134

135+
## 5. Uninstall Feast
136+
```text
137+
kustomize build feast/base | kubectl delete -n feast -f -
138+
```
126139
## 6. Troubleshooting
127140

128141
When running the minimal\_ride\_hailing\_example Jupyter Notebook example the following errors may occur:
@@ -169,4 +182,3 @@ When running the minimal\_ride\_hailing\_example Jupyter Notebook example the fo
169182
```text
170183
os.environ["DEMO_KAFKA_BROKERS"] = "feast-release-kafka:9092"
171184
```
172-

docs/getting-started/install-feast/README.md

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,8 @@ This guide installs Feast into an Azure environment using Terraform. The Terrafo
2626

2727
This guide installs Feast into a Google Cloud environment using Terraform. The Terraform script is opinionated and intended to allow you to start quickly.
2828

29-
## IBM Cloud Kubernetes Service \(IKS\) \(using Helm\)
29+
## IBM Cloud Kubernetes Service \(IKS\) and Red Hat OpenShift \(using Kustomize\)
3030

31-
This guide installs Feast into an existing [IBM Cloud Kubernetes Service](https://www.ibm.com/cloud/kubernetes-service) using Helm.
32-
33-
{% page-ref page="ibm-cloud-iks-with-helm.md" %}
31+
This guide installs Feast into an existing [IBM Cloud Kubernetes Service](https://www.ibm.com/cloud/kubernetes-service) or [Red Hat OpenShift on IBM Cloud](https://www.ibm.com/cloud/openshift) using Kustomize.
3432

33+
{% page-ref page="ibm-cloud-iks-with-kustomize.md" %}

docs/feast-on-kubernetes/getting-started/install-feast/ibm-cloud-iks-with-helm.md renamed to docs/getting-started/install-feast/ibm-cloud-iks-with-kustomize.md

Lines changed: 36 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,28 @@
1-
# IBM Cloud Kubernetes Service \(IKS\) \(with Helm\)
1+
# IBM Cloud Kubernetes Service and Red Hat OpenShift \(with Kustomize\)
22

33
## Overview
44

5-
This guide installs Feast on an existing IBM Cloud Kubernetes cluster, and ensures the following services are running:
5+
This guide installs Feast on an existing IBM Cloud Kubernetes cluster or Red Hat OpenShift on IBM Cloud , and ensures the following services are running:
66

77
* Feast Core
88
* Feast Online Serving
99
* Postgres
1010
* Redis
11+
* Kafka \(Optional\)
1112
* Feast Jupyter \(Optional\)
1213
* Prometheus \(Optional\)
14+
15+
## 1. Prerequisites
1316

14-
## 1. Requirements
15-
16-
1. [IBM Cloud Kubernetes Service](https://www.ibm.com/cloud/kubernetes-service)
17-
2. Install [Kubectl](https://cloud.ibm.com/docs/containers?topic=containers-cs_cli_install#kubectl) that matches the major.minor versions of your IKS.
17+
1. [IBM Cloud Kubernetes Service](https://www.ibm.com/cloud/kubernetes-service) or [Red Hat OpenShift on IBM Cloud](https://www.ibm.com/cloud/openshift)
18+
2. Install [Kubectl](https://cloud.ibm.com/docs/containers?topic=containers-cs_cli_install#kubectl) that matches the major.minor versions of your IKS or Install the [OpenShift CLI](https://cloud.ibm.com/docs/openshift?topic=openshift-openshift-cli#cli_oc) that matches your local operating system and OpenShift cluster version.
1819
3. Install [Helm 3](https://helm.sh/)
20+
4. Install [Kustomize](https://kubectl.docs.kubernetes.io/installation/kustomize/)
21+
22+
## 2. Preparation
23+
### IBM Cloud Block Storage Setup (IKS only)
1924

20-
## 2. IBM Cloud Block Storage Setup
25+
:warning: If you have Red Hat OpenShift Cluster on IBM Cloud skip to this [section](#Security-Context-Constraint-Setup).
2126

2227
By default, IBM Cloud Kubernetes cluster uses [IBM Cloud File Storage](https://www.ibm.com/cloud/file-storage) based on NFS as the default storage class, and non-root users do not have write permission on the volume mount path for NFS-backed storage. Some common container images in Feast, such as Redis, Postgres, and Kafka specify a non-root user to access the mount path in the images. When containers are deployed using these images, the containers fail to start due to insufficient permissions of the non-root user creating folders on the mount path.
2328

@@ -79,39 +84,43 @@ Therefore, to deploy Feast we need to set up [IBM Cloud Block Storage](https://c
7984
```text
8085
ibmc-block-gold (default) ibm.io/ibmc-block 65s
8186
```
87+
### Security Context Constraint Setup
8288

83-
**3. Preparation**
84-
85-
Add the Feast Helm repository and download the latest charts:
89+
By default, in OpenShift, all pods or containers will use the [Restricted SCC](https://docs.openshift.com/container-platform/4.6/authentication/managing-security-context-constraints.html) which limits the UIDs pods can run with, causing the Feast installation to fail. To overcome this, you can allow Feast pods to run with any UID by executing the following:
8690

8791
```text
88-
helm repo add feast-charts https://feast-helm-charts.storage.googleapis.com
89-
helm repo update
92+
oc adm policy add-scc-to-user anyuid -z default,kf-feast-kafka -n feast
9093
```
94+
## 3. Installation
9195

92-
Feast includes a Helm chart that installs all necessary components to run Feast Core, Feast Online Serving, and an example Jupyter notebook.
93-
94-
Feast Core requires Postgres to run, which requires a secret to be set on Kubernetes:
96+
Install Feast using kustomize. The pods may take a few minutes to initialize.
9597

9698
```bash
97-
kubectl create secret generic feast-postgresql --from-literal=postgresql-password=password
99+
git clone https://github.com/kubeflow/manifests
100+
cd manifests/contrib/feast/
101+
kustomize build feast/base | kubectl apply -n feast -f -
98102
```
103+
### Optional: Enable Feast Jupyter and Kafka
99104

100-
## 4. Installation
101-
102-
Install Feast using Helm. The pods may take a few minutes to initialize.
105+
You may optionally enable the Feast Jupyter component which contains code examples to demonstrate Feast. Some examples require Kafka to stream real time features to the Feast online serving. To enable, edit the following properties in the `values.yaml` under the `manifests/contrib/feast` folder:
106+
```
107+
kafka.enabled: true
108+
feast-jupyter.enabled: true
109+
```
103110

104-
```bash
105-
helm install feast-release feast-charts/feast
111+
Then regenerate the resource manifests and deploy:
112+
```
113+
make feast/base
114+
kustomize build feast/base | kubectl apply -n feast -f -
106115
```
107116

108-
## 5. Use Jupyter to connect to Feast
117+
## 4. Use Feast Jupyter to connect to Feast
109118

110119
After all the pods are in a `RUNNING` state, port-forward to the Jupyter Notebook Server in the cluster:
111120

112121
```bash
113122
kubectl port-forward \
114-
$(kubectl get pod -l app=feast-jupyter -o custom-columns=:metadata.name) 8888:8888
123+
$(kubectl get pod -l app=feast-jupyter -o custom-columns=:metadata.name) 8888:8888 -n feast
115124
```
116125

117126
```text
@@ -123,6 +132,10 @@ You can now connect to the bundled Jupyter Notebook Server at `localhost:8888` a
123132

124133
{% embed url="http://localhost:8888/tree?" caption="" %}
125134

135+
## 5. Uninstall Feast
136+
```text
137+
kustomize build feast/base | kubectl delete -n feast -f -
138+
```
126139
## 6. Troubleshooting
127140

128141
When running the minimal\_ride\_hailing\_example Jupyter Notebook example the following errors may occur:

0 commit comments

Comments
 (0)