Argo Workflows is a Kubernetes-native workflow engine that orchestrates parallel tasks using either YAML files or Python. It simplifies the automation and management of containerized applications, making it ideal for scenarios such as Continuous Integration and Continuous Delivery (CICD) pipelines, data processing, and machine learning. By installing the Argo Workflows component, you can enable batch task orchestration in your Container Service for Kubernetes (ACK) cluster, and create and manage workflow tasks through the Alibaba Cloud Argo CLI or in the console.
Step 1: Install the Argo Workflows component
Install Argo Workflows on the Add-ons page.
Log on to the ACK console. In the left-side navigation pane, click Clusters.
On the Clusters page, find the cluster that you want to manage and click its name. In the left-side navigation pane, choose .
On the Add-ons page, find Argo Workflows and install it as prompted.
After installation, choose Applications > Helm in the left-side navigation pane. If Deployed is displayed in the Status column of ack-workflow, the component is installed.
Step 2: Use Argo CLI or the console
ACK offers two methods to create and manage workflows: Alibaba Cloud Argo CLI and the Argo console.
Method 1: Install Alibaba Cloud Argo CLI
Alibaba Cloud Argo CLI is fully compatible with the open-source Argo CLI and enhances its metrics capabilities. With the Alibaba Cloud Argo CLI, you can monitor the CPU and memory resources consumed by workflows, and their operating costs. Additionally, the Alibaba Cloud Argo CLI has improved logging features, allowing you to query logs from pods that have been deleted from workflows.
Download the Alibaba Cloud Argo CLI installation package
argo-cli-aliyun-linux
.wget https://ack-one.oss-cn-hangzhou.aliyuncs.com/cli/v3.4.12/argo-cli-aliyun-linux
In this step, Linux is used as an example. The download links for Darwin and Linux systems are argo-cli-aliyun-darwin and argo-cli-aliyun-linux, respectively.
Run the following command to grant executable permissions to
argo-cli-aliyun-linux
:chmod +x argo-cli-aliyun-linux
Move the executable file to a directory included in your PATH environment variable, such as
/usr/local/bin/
. Directory paths may vary depending on the environment.mv argo-cli-aliyun-linux /usr/local/bin/argo
Method 2: Obtain the access credential and use the Argo console
1. Obtain the access credential
You can retrieve a temporary token that is valid for 1 hour from the service account in the cluster to access the Argo Server.
Run the following command to get a temporary token from the service account named argo-server
in the argo
namespace:
kubectl create token argo-server -n argo
Expected output:
elxxxxxxxxxx
2. Access the Argo console
With the access credential, you can use the Argo console. By default, an internal endpoint is provided by the system, and you can enable Internet access based on your business requirements.
(Optional) Enable Internet access and configure access control.
Run the following command to edit the Argo Server Service and set the value of
type
toLoadBalancer
:kubectl edit service argo-server -n argo
To configure the access control for traffic management, see Work with the access control feature of SLB.
Run the following command to retrieve the public IP of the Argo Server Service, which is the value of the
EXTERNAL-IP
field. This IP address is used to access the Service.kubectl get service argo-server -n argo
Use the following format to enter the public IP and port in the browser address bar:
https://${IP}:2746
Expected output:
Enter the access credential you obtained in the preceding step into the text box to log on to the console. The input should follow the format
Bearer $token
.After you log on, enter the NAMESPACE as argo and check the status of the task.
Additional step
After you complete the preceding steps, you can quickly create a sample workflow in the ACK cluster using the CLI or console. For more information, see Create a workflow.