Alibaba Cloud Container Service for Kubernetes (ACK) provides various serverless containers based on virtual nodes and elastic container instances. For example, serverless Kubernetes (ASK) clusters enable seamless integration of Kubernetes and Elastic Container Instance (ECI). This topic describes how to use Alibaba Cloud Service Mesh (ASM) to manage applications deployed in pods that run on elastic container instances in ASK clusters.
- An ASK cluster is created. For more information, see ASK quick start. Note To use the service discovery feature, you must set the service discovery mode to PrivateZone or CoreDNS when you create an ASK cluster.
- The ASK cluster is added to your ASM instance. For more information, see Add a cluster to an ASM instance.
Enable automatic sidecar injection
After you enable automatic sidecar injection for a namespace in the ASM console, an Envoy proxy is automatically injected as a sidecar into each pod that is created in the namespace. These Envoy proxies comprise the data plane of the ASM instance.
- Log on to the ASM console.
- In the left-side navigation pane, choose .
- On the Mesh Management page, find the ASM instance that you want to configure. Click the name of the ASM instance or click Manage in the Actions column.
- On the details page of the ASM instance, choose in the left-side navigation pane.
- On the Global Namespace page, find the namespace for which you want to enable automatic sidecar injection and click Enable Automatic Sidecar Injection in the Automatic Sidecar Injection column.
- In the message that appears, click OK.
Create an application that runs in an Elastic Container Instance-based pod
- Run the following command to deploy the NGINX application:
kubectl run nginx -n default --image nginx
- Run the following command to view the information about the pods that run on virtual nodes:
kubectl get pod -n default -o wide|grep virtual-kubelet
Why am I unable to enable service discovery for an ASK cluster?
If the logs of containers where sidecars are injected indicate that the istiod.istio-system service is resolved to an invalid IP address, the Alibaba Cloud DNS PrivateZone service is not activated. You can activate the Alibaba Cloud DNS PrivateZone service or install CoreDNS on the Add-ons page in the ACK console. For more information about how to manage system components on the Add-ons page, see Manage system components.