1.10. Creating a route to use for AI queries in MicroShift
Create a route so that your AI model can receive queries and give output. You can either use the oc expose svc command or create a definition in a YAML file and apply it.
Prerequisites
- You have root user access to your machine.
-
The OpenShift CLI (
oc) is installed.
Procedure
Create a route using the following command:
$ oc expose svc -n ai-demo ovms-resnet50-predictorExample output
route.route.openshift.io/ovms-resnet50-predictor exposed
Verification
Verify that the route you created exists by running the following command:
$ oc get route -n ai-demoExample output
NAME HOST ADMITTED SERVICE TLS ovms-resnet50-predictor ovms-resnet50-predictor-ai-demo.apps.example.com True ovms-resnet50-predictor
Additional resources