Best Practices for Spring Cloud Applications in Kubernetes: Deployment (Development and Deployment)

Initialize Clusters

  1. Log on to the Container Service for Kubernetes console to create an ACK cluster.
  2. If you already have a cluster created in a cloud or a cluster created from other Internet data centers (IDCs) or vendors, you can import it to Container Service for Kubernetes by clicking Register Existing Cluster.
  1. Initializes the cluster controllers and related resources in EDAS, including the Open Application Model (OAM) controllers based on the standards of cloud-native open applications, the agent for log collection, and the information about the Application Real-Time Monitoring Service (ARMS) environment in the monitoring process. Most of the controllers will run in a management cluster that is hosted in and maintained by EDAS. Therefore, they will not occupy any resources in your cluster.
  2. Defines the relationships between the cluster and the namespaces in EDAS based on your plans. Namespaces in EDAS are used to isolate services and configuration. To put it simply, they can be used to isolate environments in daily research and development, such as development, testing, and production environments. When you import a cluster, you will also confirm the environment where the cluster is used.

Initialize Applications

  1. Java, Tomcat, and EDAS Container environments: If you choose one of these runtime environments, EDAS will pack the uploaded file and the corresponding base image into an image of the application.
  2. Custom environment: If you select the runtime environment that uses an image, each deployment will be performed with a specified custom image. A custom image must meet certain specifications. For more information, see Create Docker images for applications in the documentation of Alibaba Cloud. The core is the following code:
# Inherit the official image in EDAS.
FROM apaas/edas
# Download the file to the /home/admin/app directory.
ADD http://your.domain.com/file/location.jar /home/admin/app/

Directly Deploy Kubernetes Applications by Using the IDE Plug-In

Summary and What to Do Next

Original Source:

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Alibaba Cloud

Alibaba Cloud

Follow me to keep abreast with the latest technology news, industry insights, and developer trends. Alibaba Cloud website:https://www.alibabacloud.com