Configure External Access for Inference Services
TOC
Introduction
This document provides a step-by-step guide on how to configure external access for your inference services, including checking external access addresses, creating domains, setting up load balancers, and verifying the configuration.
Steps
1. View External Access Address of the Inference Service
You can:
- Navigate to the service details page and copy the address from the Access Method card, or
- View the address in the YAML card under
status.url.
2. Create a Domain
In the Administrator Console, go to Network > Domains, and then click Create Domain.
- In the Domain field, enter the domain name of your inference service, excluding the protocol (e.g., qwen2-0b5-kubeflow-admin-cpaas-io.my-company.com).
- For Allocated To (Cluster), select the cluster where your service is located.
- For Allocated Projects, choose the project where your inference service resides.
3. Create a Load Balancer
(One load balancer can be shared by multiple projects; create a new one only if necessary.)
In the Administrator Console, go to Network > Load Balancers, and then click Create Load Balancer. For detailed help documentation, please refer to .
4. Configure the Load Balancer
In the Alauda Container Platform Console, navigate to Network > Load Balancers, then click the name of the load balancer you just created to enter its configuration page.
4.1 Ports Configuration
Add listening ports for your service. You can add more ports as needed.
Step 1: Add a Port
- In the Port Management section, click the Add Port button.
- In the configuration page, select a protocol (HTTP or HTTPS).
- Enter the corresponding port number. For HTTP, the standard port is
80. For HTTPS, the standard port is443.
Step 2: Configure HTTPS (if applicable) If you choose the HTTPS protocol, you must select a default certificate.
- Ensure you have switched to the
istio-systemnamespace. This is crucial for the next step. - Select
knative-serving-certas the Default Certificate.
4.2 Rules Configuration
Configure forwarding rules for the ports you added in the previous step.
Step 1: Add a Rule
- In the Rules section, click the Add Rule button.
- On the configuration page, click the Add Rule Indicator button to add your first rule.
- For Type, select Domains.
- From the dropdown menu, choose the domain name you created for your inference service, for example:
qwen2-0b5-kubeflow-admin-cpaas-io.my-company.com.
Step 2: Configure the Service Group
- Locate the Service Group configuration area.
- Ensure the Namespace is set to
istio-system. If not, switch your project's namespace toistio-systemfirst. - Under Services, select
knative-ingressgatewayfrom the dropdown list. - Choose port 80.
Note: The process for configuring rules for the HTTPS protocol (port 443) is the same as described above.
For more detailed parameter configurations, you can refer to .
5. Verify Access to the Inference Service via External Address
To verify that your inference service is accessible externally, use the curl command below. Remember to replace the placeholders with your actual load balancer IP address, port, and inference service address.
Here's what each part of the command means and what you need to replace:
your-inference-service-domain.com: This should be the domain name you created for your inference service (e.g.,qwen2-0b5-kubeflow-admin-cpaas-io.my-company.com).your-port: This is the port your load balancer is listening on for HTTP traffic (commonly80).your-load-balancer-ip: This is the actual IP address of your load balancer (e.g.,192.168.137.21).
If the request successfully returns the model list, your configuration is complete! If it fails, double-check your load balancer settings or review the inference service logs to pinpoint the problem.