This topic describes how to create a Kubernetes application by using a Deployment.
Usage notes
Enterprise Distributed Application Service (EDAS) specifies parameters for registries and Java virtual machine (JVM) by configuring the CATALINA_OPTS environment variable. You must reference the CATALINA_OPTS environment variable in the command that is used to start an application.
By default, the Java microservice applications deployed in the EDAS console use the registries that are associated with the current microservice namespace, such as the shared service registry of EDAS and the exclusive Microservices Engine (MSE) Nacos registry. If you want to connect to a self-managed registry, select Use the service registry configured for the application when you configure the Microservices Governance parameter. For more information, see Configure microservices governance.
Only the following parameters are supported by Deployments.
Parameter
Parsing
Description
metadata (the name of the EDAS application or EDAS application namespace)
Supported
Labels and annotations for Deployments are not supported.
selector
Not supported
EDAS automatically generates the configuration.
strategy
Not supported
The manual release, batch release, and canary release strategies are supported by the EDAS console.
replicas
Supported
The number of application instances.
template
Partially supported
For more information, see the following parameters that start with template.
template.metadata (labels and annotations)
Supported
For more information, see Add labels to application pods and Configure annotations.
template.spec.affinity
Supported
For more information, see Configure scheduling rules.
template.spec.tolerations
Supported
For more information, see Configure scheduling rules.
template.spec.dnsConfig
Not supported
You can configure this parameter in the EDAS console. For more information, see Configure DNS settings.
template.spec.dnsPolicy
Not supported
You can configure this parameter in the EDAS console. For more information, see Configure DNS settings.
template.spec.hostAliases
Not supported
You can configure this parameter in the EDAS console. For more information, see Configure DNS settings.
template.spec.imagePullSecrets
Not supported
Configure the aliyun-acr-credential-helper component. For more information, see Use the aliyun-acr-credential-helper component to pull images without using a password.
template.spec.initContainers
Not supported
You can configure this parameter in the EDAS console. For more information, see Configure sidecar containers and init containers.
template.spec.nodeSelector
Not supported
We recommend that you use affinity.
template.spec.nodeName
Not supported
We recommend that you use affinity.
template.spec.schedulerName
Not supported
None.
template.spec.securityContext
Not supported
None.
template.spec.serviceAccount
Not supported
None.
template.spec.volume
Not supported
You can configure this parameter in the EDAS console. For more information, see Configure persistent storage.
template.spec.containers
Partially supported
Only one container can be configured. You can configure a sidecar container in the EDS console.
container.args
Supported
For more information, see Configure a startup command.
container.command
Supported
For more information, see Configure a startup command.
container.env
Supported
For more information, see Configure environment variables.
container.envFrom
Not supported
You can configure this parameter in the EDAS console. For more information, see Configure environment variables.
container.image
Supported
The URL of the image.
container.imagePullPolicy
Not supported
Default value: Always.
container.lifecycle(preStop/postStart)
Supported
For more information, see Configure application lifecycle hooks and probes.
container.livenessProbe
Supported
For more information, see Configure application lifecycle hooks and probes.
container.readinessProbe
Supported
For more information, see Configure application lifecycle hooks and probes.
container.startupProbe
Not supported
None.
container.resources
Partially supported
Only CPU and memory resources can be parsed.
container.ports
Not supported
None.
container.volumeMounts
Not supported
You can configure this parameter in the EDAS console. For more information, see Configure local storage.
Procedure
-
EDAS console Log on to the . In the left-side navigation pane, choose . In the top navigation bar, select a region. In the upper part of the page, select a microservice namespace. In the upper-left corner of the Applications page, click Create Application.
In the Basic Information step, configure the Cluster Type and Application Source Type parameters. Then, click Next.
Parameter
Description
Cluster Type
The type of the cluster in which you want to deploy the application. Select Kubernetes Clusters.
Application Source Type
The type of the application source. Select Deployment.
If you set the DeploymentSource parameter to Container Cluster, you must select the cluster, namespace, and Deployment from the drop-down lists.
If you set the DeploymentSource parameter to Upload YAML file, click browse local files to upload a YAML file. The system automatically parses the content of the YAML file for the Deployment on the right of the page.
In the Configurations step, select a microservice namespace from the Microservice Namespace drop-down list and a cluster from the Cluster drop-down list based on your business requirements. Click Next.
In the Advanced Settings step, click Next.
-
After you configure the advanced settings, click Create Application. In the Creation Completed step, click Create Application.
-
In the Confirm Application Change Precheck dialog box, click Start Precheck.
-
After the data in the dialog box is refreshed, confirm the precheck items and results and click Continue.
-
(Optional) If you modify the preceding precheck items, click Check Again.
The application requires several minutes to be deployed. During the process, you can view the change records to track the deployment progress of the application on the Change List page. After you deploy the application, go to the Application Overview page to view the running status of pods. If the pods are in the running state, the application is deployed. You can click the running status of pods to view the Deployments, pods, and advanced configurations of the application instances.
-