Step‑by‑Step Guide to Deploy Knative on Alibaba Cloud
This tutorial introduces Knative, explains its architecture and core components, and provides a detailed, image‑rich walkthrough for deploying Knative on Alibaba Cloud, testing a sample serverless application, and managing the cluster via CloudShell.
Introduction
Knative is a Kubernetes‑based serverless framework that defines a cloud‑native, cross‑platform standard for orchestrating serverless workloads.
Architecture and Roles
Knative integrates three capabilities: container building (or functions), workload management with dynamic scaling, and an event model. The architecture involves:
Developers who use native Kubernetes APIs to deploy serverless services.
Contributors who maintain the open‑source project.
Integrators such as cloud providers or internal platforms that embed Knative.
End users who access services through an Istio gateway.
Core Components
Tekton : Provides a generic source‑to‑image build pipeline; each step runs inside a Kubernetes pod.
Eventing : Handles event ingestion, registration, subscription, filtering and decouples producers from consumers, supporting both pre‑ and post‑production event handling.
Serving : Manages serverless workloads, offers request‑driven autoscaling down to zero, and supports gradual rollouts.
Deploying Knative on Alibaba Cloud
Log in to the Alibaba Cloud Container Service console.
If no cluster exists, create a Kubernetes cluster and wait until its status becomes Running .
In the console, navigate to Applications → Knative and click One‑click Deploy .
After deployment completes, verify that the core components (Tekton, Eventing, Serving) show a status of Deployed .
Testing the Serverless Application
Allocate an Elastic IP (EIP) in the Alibaba Cloud console and bind it to the kubernetes API Server Service.
Create a sample Kantive application using the built‑in template in the Knative console.
After creation, the console lists the new serverless service.
Add a host entry mapping the allocated EIP to the service domain, e.g.:
101.200.87.158 helloworld-go.default.example.comThis entry should be placed in /etc/hosts (Linux/macOS) or C:\Windows\System32\drivers\etc\hosts (Windows).
Open the domain helloworld-go.default.example.com in a web browser; the expected response from the sample application is displayed.
Managing the Cluster with CloudShell
From the cluster list in the Alibaba Cloud console, click CloudShell to open an interactive terminal that runs inside the cluster.
Execute the following command to list the Knative components that were installed: kubectl get knative The output shows the Tekton pipelines, Eventing resources, and Serving services in a Ready state.
Signed-in readers can open the original source through BestHub's protected redirect.
This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactand we will review it promptly.
Alibaba Cloud Native
We publish cloud-native tech news, curate in-depth content, host regular events and live streams, and share Alibaba product and user case studies. Join us to explore and share the cloud-native insights you need.
How this landed with the community
Was this worth your time?
0 Comments
Thoughtful readers leave field notes, pushback, and hard-won operational detail here.
