K8sApplicationProps
Properties for defining a K8sApplication
.
See https://www.alibabacloud.com/help/ros/developer-reference/aliyun-edas-k8sapplication
Initializer
import "github.com/alibabacloud-go/ros-cdk/alicloudroscdkedas"
&alicloudroscdkedas.K8sApplicationProps {
AppName: interface{},
ClusterId: interface{},
ApplicationDescription: interface{},
Command: interface{},
CommandArgs: interface{},
DeployAcrossNodes: interface{},
DeployAcrossZones: interface{},
EdasContainerVersion: interface{},
EnableAhas: interface{},
Envs: interface{},
ImageUrl: interface{},
InternetSlbId: interface{},
InternetSlbPort: interface{},
InternetSlbProtocol: interface{},
InternetTargetPort: interface{},
IntranetSlbId: interface{},
IntranetSlbPort: interface{},
IntranetSlbProtocol: interface{},
IntranetTargetPort: interface{},
IsMultilingualApp: interface{},
JavaStartUpConfig: interface{},
Jdk: interface{},
LimitCpu: interface{},
LimitMem: interface{},
Liveness: interface{},
LocalVolume: interface{},
LogicalRegionId: interface{},
MountDescs: interface{},
Namespace: interface{},
NasId: interface{},
PackageType: interface{},
PackageUrl: interface{},
PackageVersion: interface{},
PostStart: interface{},
PreStop: interface{},
Readiness: interface{},
Replicas: interface{},
RepoId: interface{},
RequestsCpu: interface{},
RequestsMem: interface{},
RuntimeClassName: interface{},
SlsConfigs: interface{},
StorageType: interface{},
Timeout: interface{},
UriEncoding: interface{},
UseBodyEncoding: interface{},
WebContainer: interface{},
WebContainerConfig: interface{},
}
Properties
Name | Type | Description |
---|---|---|
AppName |
interface{} |
Property appName: The name of the application. |
ClusterId |
interface{} |
Property clusterId: The cluster ID. |
ApplicationDescription |
interface{} |
Property applicationDescription: The description of the application. |
Command |
interface{} |
Property command: The command that is specified. |
CommandArgs |
interface{} |
Property commandArgs: The collection of commands. |
DeployAcrossNodes |
interface{} |
Property deployAcrossNodes: Specifies whether to distribute application instances to multiple nodes. |
DeployAcrossZones |
interface{} |
Property deployAcrossZones: Specifies whether to distribute application instances to multiple zones. |
EdasContainerVersion |
interface{} |
Property edasContainerVersion: The version of EDAS Container on which the deployment package of the application depends. |
EnableAhas |
interface{} |
Property enableAhas: Specifies whether to enable access to Application High Availability Service (AHAS). |
Envs |
interface{} |
Property envs: The collection of deployment environment variables. |
ImageUrl |
interface{} |
Property imageUrl: The image URL. |
InternetSlbId |
interface{} |
Property internetSlbId: The ID of the Internet-facing SLB instance. |
InternetSlbPort |
interface{} |
Property internetSlbPort: The frontend port of the Internet-facing SLB instance. |
InternetSlbProtocol |
interface{} |
Property internetSlbProtocol: The protocol of the Internet-facing SLB instance. |
InternetTargetPort |
interface{} |
Property internetTargetPort: The backend port of the internal-facing SLB instance, which is also the service port of the application. |
IntranetSlbId |
interface{} |
Property intranetSlbId: The ID of the internal-facing SLB instance. |
IntranetSlbPort |
interface{} |
Property intranetSlbPort: The frontend port of the internal-facing SLB instance. |
IntranetSlbProtocol |
interface{} |
Property intranetSlbProtocol: The protocol of the internal-facing SLB instance. |
IntranetTargetPort |
interface{} |
Property intranetTargetPort: The backend port of the internal-facing Server Load Balancer (SLB) instance, which is also the service port of the application. |
IsMultilingualApp |
interface{} |
Property isMultilingualApp: Specifies whether the application is a multi-language application. |
JavaStartUpConfig |
interface{} |
Property javaStartUpConfig: The configuration of Java startup parameters for a Java application. |
Jdk |
interface{} |
Property jdk: The version of Java Development Kit (JDK) on which the deployment package of the application depends. |
LimitCpu |
interface{} |
Property limitCpu: The maximum number of CPUs allowed for each application instance when the application is running. |
LimitMem |
interface{} |
Property limitMem: The maximum amount of memory allowed for each application instance when the application is running. |
Liveness |
interface{} |
Property liveness: The liveness check on the container. |
LocalVolume |
interface{} |
Property localVolume: The configuration for mounting host files to the container where the application is running. |
LogicalRegionId |
interface{} |
Property logicalRegionId: The ID of the EDAS namespace. |
MountDescs |
interface{} |
Property mountDescs: The description of the NAS mounting configuration. |
Namespace |
interface{} |
Property namespace: The namespace of the Kubernetes cluster. |
NasId |
interface{} |
Property nasId: The ID of the Network Attached Storage (NAS) file system mounted to the container where the application is running. |
PackageType |
interface{} |
Property packageType: The type of the deployment package. |
PackageUrl |
interface{} |
Property packageUrl: The URL of the deployment package. |
PackageVersion |
interface{} |
Property packageVersion: The version of the deployment package. |
PostStart |
interface{} |
Property postStart: The post-start script. |
PreStop |
interface{} |
Property preStop: The pre-stop script. |
Readiness |
interface{} |
Property readiness: The readiness check on the container. |
Replicas |
interface{} |
Property replicas: The number of instances for the application that you want to create. |
RepoId |
interface{} |
Property repoId: The ID of the image repository. |
RequestsCpu |
interface{} |
Property requestsCpu: The maximum number of CPUs allowed for each application instance when the application is created. |
RequestsMem |
interface{} |
Property requestsMem: The maximum amount of memory allowed for each application instance when the application is created. |
RuntimeClassName |
interface{} |
Property runtimeClassName: The type of the container runtime. |
SlsConfigs |
interface{} |
Property slsConfigs: The Logstore configurations. |
StorageType |
interface{} |
Property storageType: Only SSD is supported. |
Timeout |
interface{} |
Property timeout: The timeout interval of the change process. |
UriEncoding |
interface{} |
Property uriEncoding: The uniform resource identifier (URI) encoding scheme. |
UseBodyEncoding |
interface{} |
Property useBodyEncoding: Specifies whether useBodyEncodingForURI is enabled. |
WebContainer |
interface{} |
Property webContainer: The version of the Tomcat container on which the deployment package of the application depends. |
WebContainerConfig |
interface{} |
Property webContainerConfig: The Tomcat container configuration. |
AppName
Required
AppName interface{}
- Type: interface{}
Property appName: The name of the application.
The name must start with a letter and can contain digits, letters, and hyphens (-). It can be up to 36 characters in length.
ClusterId
Required
ClusterId interface{}
- Type: interface{}
Property clusterId: The cluster ID.
You can query the cluster ID by calling the ListCluster operation. For more information, see ListCluster.
ApplicationDescription
Optional
ApplicationDescription interface{}
- Type: interface{}
Property applicationDescription: The description of the application.
Command
Optional
Command interface{}
- Type: interface{}
Property command: The command that is specified.
If it is specified, it replaces the startup command in the image when the image is started.
CommandArgs
Optional
CommandArgs interface{}
- Type: interface{}
Property commandArgs: The collection of commands.
For example, [{"argument":"-c"},{"argument":"test"}], where -c and test are two parameters that can be set.
DeployAcrossNodes
Optional
DeployAcrossNodes interface{}
- Type: interface{}
Property deployAcrossNodes: Specifies whether to distribute application instances to multiple nodes.
The value true indicates yes, whereas other values indicate no.
DeployAcrossZones
Optional
DeployAcrossZones interface{}
- Type: interface{}
Property deployAcrossZones: Specifies whether to distribute application instances to multiple zones.
The value true indicates yes, whereas other values indicate no.
EdasContainerVersion
Optional
EdasContainerVersion interface{}
- Type: interface{}
Property edasContainerVersion: The version of EDAS Container on which the deployment package of the application depends.
Note This parameter is not supported when you deploy an application by using images.
EnableAhas
Optional
EnableAhas interface{}
- Type: interface{}
Property enableAhas: Specifies whether to enable access to Application High Availability Service (AHAS).
Envs
Optional
Envs interface{}
- Type: interface{}
Property envs: The collection of deployment environment variables.
For example, [{"Name":"x","Value":"y"},{"Name":"x2","Value":"y2"}].
ImageUrl
Optional
ImageUrl interface{}
- Type: interface{}
Property imageUrl: The image URL.
When PackageType is set to Image, this parameter is required.
InternetSlbId
Optional
InternetSlbId interface{}
- Type: interface{}
Property internetSlbId: The ID of the Internet-facing SLB instance.
If this parameter is not specified, EDAS automatically purchases a new SLB instance for you.
InternetSlbPort
Optional
InternetSlbPort interface{}
- Type: interface{}
Property internetSlbPort: The frontend port of the Internet-facing SLB instance.
Valid values: 1 to 65535.
InternetSlbProtocol
Optional
InternetSlbProtocol interface{}
- Type: interface{}
Property internetSlbProtocol: The protocol of the Internet-facing SLB instance.
Valid values: TCP, HTTP, and HTTPS.
InternetTargetPort
Optional
InternetTargetPort interface{}
- Type: interface{}
Property internetTargetPort: The backend port of the internal-facing SLB instance, which is also the service port of the application.
Valid values: 1 to 65535.
IntranetSlbId
Optional
IntranetSlbId interface{}
- Type: interface{}
Property intranetSlbId: The ID of the internal-facing SLB instance.
If this parameter is not specified, Enterprise Distributed Application Service (EDAS) automatically purchases a new SLB instance for you.
IntranetSlbPort
Optional
IntranetSlbPort interface{}
- Type: interface{}
Property intranetSlbPort: The frontend port of the internal-facing SLB instance.
Valid values: 1 to 65535.
IntranetSlbProtocol
Optional
IntranetSlbProtocol interface{}
- Type: interface{}
Property intranetSlbProtocol: The protocol of the internal-facing SLB instance.
Valid values: TCP, HTTP, and HTTPS.
IntranetTargetPort
Optional
IntranetTargetPort interface{}
- Type: interface{}
Property intranetTargetPort: The backend port of the internal-facing Server Load Balancer (SLB) instance, which is also the service port of the application.
Valid values: 1 to 65535.
IsMultilingualApp
Optional
IsMultilingualApp interface{}
- Type: interface{}
Property isMultilingualApp: Specifies whether the application is a multi-language application.
JavaStartUpConfig
Optional
JavaStartUpConfig interface{}
- Type: interface{}
Property javaStartUpConfig: The configuration of Java startup parameters for a Java application.
These startup parameters involve the memory, application, garbage collection (GC) policy, tools, service registration and discovery, and custom configurations. Proper parameter settings help reduce the GC overhead, shorten the server response time, and improve the throughput. The system automatically concatenates all startup values as the configuration of Java startup parameters for the application.
Jdk
Optional
Jdk interface{}
- Type: interface{}
Property jdk: The version of Java Development Kit (JDK) on which the deployment package of the application depends.
Valid values: Open JDK 7 and Open JDK 8. This parameter is not supported when you deploy an application by using images.
LimitCpu
Optional
LimitCpu interface{}
- Type: interface{}
Property limitCpu: The maximum number of CPUs allowed for each application instance when the application is running.
Unit: cores.
LimitMem
Optional
LimitMem interface{}
- Type: interface{}
Property limitMem: The maximum amount of memory allowed for each application instance when the application is running.
Unit: MB.
Liveness
Optional
Liveness interface{}
- Type: interface{}
Property liveness: The liveness check on the container.
LocalVolume
Optional
LocalVolume interface{}
- Type: interface{}
Property localVolume: The configuration for mounting host files to the container where the application is running.
For example, the value can be [{"type":"", "nodePath":"/localfiles", "mountPath":"/app/files"}, {"type":"Directory", "nodePath":"/mnt", "mountPath":"/app/storage"}].
LogicalRegionId
Optional
LogicalRegionId interface{}
- Type: interface{}
Property logicalRegionId: The ID of the EDAS namespace.
This parameter is required for a non-default namespace.
MountDescs
Optional
MountDescs interface{}
- Type: interface{}
Property mountDescs: The description of the NAS mounting configuration.
For example, the value can be [{"NasPath": "/k8s","MountPath": "/mnt"}, {"NasPath": "/files", "MountPath": "/app/files"}].
Namespace
Optional
Namespace interface{}
- Type: interface{}
Property namespace: The namespace of the Kubernetes cluster.
This parameter determines the Kubernetes namespace where your application is deployed. By default, this parameter is set to default.
NasId
Optional
NasId interface{}
- Type: interface{}
Property nasId: The ID of the Network Attached Storage (NAS) file system mounted to the container where the application is running.
The NAS file system must be in the same region as the cluster. The NAS file system must have an available mount target, or have a mount target on the vSwitch in the virtual private cloud (VPC) where the application is located. If this parameter is not specified and the mountDescs field exists, a NAS file system is automatically purchased and mounted to the vSwitch in the VPC by default.
PackageType
Optional
PackageType interface{}
- Type: interface{}
Property packageType: The type of the deployment package.
Valid values: FatJar, WAR, and Image.
PackageUrl
Optional
PackageUrl interface{}
- Type: interface{}
Property packageUrl: The URL of the deployment package.
This parameter must be set for the applications that are deployed by using FatJar or WAR packages. Note The version of SDK for Java or Python must be 2.44.0 or later.
PackageVersion
Optional
PackageVersion interface{}
- Type: interface{}
Property packageVersion: The version of the deployment package.
This parameter is required when the PackageType parameter is set to WAR or FatJar. You must specify a version. Note The version of SDK for Java or Python must be 2.44.0 or later.
PostStart
Optional
PostStart interface{}
- Type: interface{}
Property postStart: The post-start script.
For example, {"Exec": {"Command": ["ls", "/"]}}.
PreStop
Optional
PreStop interface{}
- Type: interface{}
Property preStop: The pre-stop script.
For example, {"Exec": {"Command": ["ls", "/"]}}.
Readiness
Optional
Readiness interface{}
- Type: interface{}
Property readiness: The readiness check on the container.
Replicas
Optional
Replicas interface{}
- Type: interface{}
Property replicas: The number of instances for the application that you want to create.
Default: 1
RepoId
Optional
RepoId interface{}
- Type: interface{}
Property repoId: The ID of the image repository.
RequestsCpu
Optional
RequestsCpu interface{}
- Type: interface{}
Property requestsCpu: The maximum number of CPUs allowed for each application instance when the application is created.
Unit: cores. The value 0 indicates no limit.
RequestsMem
Optional
RequestsMem interface{}
- Type: interface{}
Property requestsMem: The maximum amount of memory allowed for each application instance when the application is created.
Unit: MB. The value 0 indicates no limit.
RuntimeClassName
Optional
RuntimeClassName interface{}
- Type: interface{}
Property runtimeClassName: The type of the container runtime.
This parameter is applicable only to clusters that use sandboxed containers.
SlsConfigs
Optional
SlsConfigs interface{}
- Type: interface{}
Property slsConfigs: The Logstore configurations.
StorageType
Optional
StorageType interface{}
- Type: interface{}
Property storageType: Only SSD is supported.
Timeout
Optional
Timeout interface{}
- Type: interface{}
Property timeout: The timeout interval of the change process.
Unit: seconds.
UriEncoding
Optional
UriEncoding interface{}
- Type: interface{}
Property uriEncoding: The uniform resource identifier (URI) encoding scheme.
Valid values: ISO-8859-1, GBK, GB2312, and UTF-8. Note If this parameter is not specified in application configuration, the default URI encoding scheme in the Tomcat container is applied.
UseBodyEncoding
Optional
UseBodyEncoding interface{}
- Type: interface{}
Property useBodyEncoding: Specifies whether useBodyEncodingForURI is enabled.
Note If this parameter is not specified in application configuration, the default value false is applied.
WebContainer
Optional
WebContainer interface{}
- Type: interface{}
Property webContainer: The version of the Tomcat container on which the deployment package of the application depends.
This parameter is applicable to Spring Cloud and Apache Dubbo applications that are deployed by using WAR packages. This parameter is not supported when you deploy an application by using images.
WebContainerConfig
Optional
WebContainerConfig interface{}
- Type: interface{}
Property webContainerConfig: The Tomcat container configuration.