Overview 🔗︎
Container Service (ACK) provides the high-performance and scalable container application management service, which enables you to manage the lifecycle of containerized applications by using Docker and Kubernetes.
This quickstart will guide you through the steps needed to set up an ACK cluster with Banzai Cloud Pipeline.
Prerequisites 🔗︎
- Alibaba credentials
- Banzai CLI tool authenticated against the Pipeline instance
Create an Alibaba secret 🔗︎
To access resources on Alibaba Cloud the appropriate credentials need to be registered in the Banzai Cloud Pipeline’s secret store. (The reference to this secret will be used later on instead of passing the credentials around)
Follow this guide to create Alibaba credentials
The following values are needed for the secret:
- Access Key ID
- Access Key Secret
You can create the secret with the following command (replace the values in the mustache brackets) :
banzai secret create <<EOF
{
"name": "alibaba-secret",
"type": "alibaba",
"values": {
"ALIBABA_ACCESS_KEY_ID": "{{access-key-id}}",
"ALIBABA_ACCESS_KEY_SECRET": "{{access-key-secret}}"
}
}
EOF
Id Name Type UpdatedBy Tags
b32343e28d37e09c26d91b4271eaa8dd689b16d9f1aba07fdc73af2a27750309 alibaba-secret alibaba lpuskas []
Create ACK clusters 🔗︎
Use the previously created secret to create the cluster
You can check the available regions and instance types in our Cloudinfo service.
To create an ACK cluster execute the following command:
banzai cluster create <<EOF
{
"name": "ack-cluster",
"location": "us-east-1",
"cloud": "alibaba",
"secretName": "alibaba-secret",
"properties": {
"ack": {
"regionId": "us-east-1",
"zoneId": "us-east-1b",
"masterInstanceType": "ecs.g5.6xlarge",
"masterSystemDiskCategory": "cloud_efficiency",
"nodePools": {
"pool1": {
"instanceType": "ecs.t5-lc1m2.large",
"minCount": 3,
"maxCount": 4
},
"pool2": {
"instanceType": "ecs.c5.large",
"minCount": 1,
"maxCount": 2
}
}
}
}
}
EOF
The command above initiates the creation of a cluster with 7 nodes:
- 3 master nodes of type
ecs.g5.6xlarge
provided by the service (the number of master nodes is controlled by the ACK service, it’s always 3 for now) - 3 worker nodes of type
ecs.t5-lc1m2.large
— specified in thepool1
node pool - 1 worker node of type
ecs.c5.large
— specified in thepool2
node pool
The payload json provided to the command may be altered to describe the desired ACK cluster layout (e.g. more node pools can be added with different instance types and different sizes).
Check the status of the cluster 🔗︎
To check the status of the cluster, run the following command:
banzai cluster get "<cluster-name>"
Once the cluster is ready, you can try to run some simple commands.
banzai cluster shell
executes a shell within the context of the selected cluster.
If you type a command in the shell opened, or pass arguments to it, it will be executed in a prepared environment.
For example, you can list the nodes of the cluster using the original kubectl
command by running:
banzai cluster shell --cluster-name "<cluster-name>" -- kubectl get nodes
Further steps 🔗︎
If you are happy with the results, go on with the Deploying workload guide to learn about the basic features of a cluster.