Deployment environment configuration items contain all the information required to create a deployment environment. You can duplicate configuration items, excluding resources exclusive to the deployment environment. For example, you cannot duplicate Elastic Compute Service (ECS) instances.

Platform

Path Parameter Configuration item Default value Valid values Description
proxy type Reverse proxy type nginx nginx and apache The type of the reverse proxy to use. After the reverse proxy is enabled, the system listens on port 80 of your application. Ensure that this port is not occupied by other programs. The reverse proxy forwards received HTTP requests to the service port of the application.
proxy.nginx version Nginx version 1.14.2 1.14.2 The Nginx version to use. This parameter takes effect only when the type parameter is set to nginx.
proxy.apache version Apache version 2.4.6 2.4.6 The Apache version to use. This parameter takes effect only when the type parameter is set to apache.

Resources

resources.network: Network configuration

Parameter Configuration item Default value Valid values Description
vpcOption Network options {"vpcId":"","vSwitches":[]} The Virtual Private Cloud (VPC) and VSwitch to use in the deployment environment. If multiple VSwitches are selected, Web App Service (Web+) allocates Elastic Compute Service (ECS) instances to the selected VSwitches in a balanced manner. You can create a VPC and a VSwitch in the VPC console.

resources.ecs.autoScaling: ECS configuration

Parameter Configuration item Default value Valid values Description
instanceType Instance type ["ecs.g5.large"] The type of the ECS instance to use in the deployment environment. Web+ creates ECS instances of the selected instance type. You can select a maximum of 10 instance types. When resources are insufficient for the selected instance types, Web+ tries to create ECS instances according to the sequence of selected instance types.
instanceNum Instance quantity 1 [0, 100] The number of ECS instances to use. Based on this parameter, Web+ resizes the deployment environment.
securityGroupIds Security group [] The security group of the ECS instance. You can select a maximum of five security groups.
keyPairName Key pair The key pair to use for Secure Shell (SSH) logon. For more information about how to use the SSH key pair, see Use an SSH key pair.
systemDiskSize System disk size The size of the system disk. Unit: GB.
enableInternet Whether to enable the public IP address true true and false Specifies whether to enable the public IP address. If the public IP address is enabled, all ECS instances in the deployment environment can be accessed from the public network. Pay attention to the security configuration. The services provided by ECS instances on the public network may incur charges. For more information, see the billing of Internet bandwidth.
instanceName Instance name The name of the ECS instance to create.
scalingPolicy Instance deallocation policy recycle release and recycle The deallocation policy to use for the ECS instance that is shut down. If this parameter is set to release, the system releases all resources of the ECS instance. If this parameter is set to recycle, the system retains the disks of the ECS instance, which may incur charges.
userData Custom instance data The custom data on the ECS instance. The data must be Base64-encoded. The maximum size of the raw data is 16 KB.
systemDiskCategory System disk type cloud_efficiency cloud, cloud_efficiency, cloud_ssd, and ephemeral_ssd The type of the system disk. A value of cloud indicates the basic disk. A value of cloud_efficiency indicates the ultra disk. A value of cloud_ssd indicates the SSD. A value of ephemeral_ssd indicates the local SSD. When Generation I and non I/O-optimized instance types are selected, the default value of this parameter is cloud. Otherwise, the default value is cloud_efficiency.
multiAzPolicy Multi-zone scaling policy BALANCE PRIORITY and BALANCE The scaling policy for ECS instances in a multi-zone scaling group. If this parameter is set to PRIORITY, the system scales out or in ECS instances based on your VSwitches specified by the VSwitchIds.N parameter. This policy allows the system to create ECS instances in the zone of the secondary VSwitch when the system fails to create ECS instances in the zone of the primary VSwitch. If this parameter is set to BALANCE, the system allocates ECS instances in a balanced manner among multiple zones specified by the scaling group. If ECS instances become imbalanced among multiple zones due to a lack of instance resources, you can call the RebalanceInstances operation of Auto Scaling to balance the allocation of resources.
internetChargeType Internet billing type PayByTraffic PayByBandwidth and PayByTraffic The billing method on the public network. If this parameter is set to PayByBandwidth, the network service is billed by fixed bandwidth. In this case, the fixed bandwidth is the maximum available outbound bandwidth specified by the internetMaxBandwidthOut parameter. If this parameter is set to PayByTraffic, the network service is billed by traffic usage. In this case, the internetMaxBandwidthOut parameter specifies only the upper limit of available bandwidth.
internetMaxBandwidthIn Maximum inbound bandwidth from the public network 100 [1, 200] The maximum inbound bandwidth from the public network. Unit: Mbit/s. If you do not specify this parameter, it is set to 200 by default. This parameter is not used for billing because the inbound traffic to ECS instances is free of charge.
internetMaxBandwidthOut Maximum outbound bandwidth to the public network 50 [0, 100] The maximum outbound bandwidth to the public network. Unit: Mbit/s. If the internetChargeType parameter is set to PayByBandwidth but you do not specify this parameter, it is set to 0 by default. If the internetChargeType parameter is set to PayByTraffic but you do not specify this parameter, the system reports an error.
ioOptimized I/O optimized instance true true and false Specifies whether the ECS instance is an I/O optimized instance.

resources.slb.internet: Public network SLB configuration

Parameter Configuration item Default value Valid values Description
enable Whether to enable public network SLB true true and false Specifies whether to enable public network SLB. If multiple ECS instances exist in the deployment environment, you can create or configure an SLB instance in the SLB console for load balancing.
slbId SLB instance ID The ID of the public network SLB instance. You can use an existing SLB instance or enable Web+ to purchase an SLB instance.
listenerPort SLB listener port 80 [1, 65535] The listener port of the public network SLB instance. This port enables you to access the application from the public network.
protocol SLB protocol http http and tcp The protocol type of the public network SLB instance.
forwardingRule SLB routing method The routing method of the public network SLB instance.
bandwidth Peak bandwidth on the listener port -1 [-1, 5120] The peak bandwidth on the listener port.
loadBalancerSpec SLB instance type slb.s1.small slb.s1.small, slb.s2.small, slb.s2.medium, slb.s3.small, slb.s3.medium, and slb.s3.large The type of the public network SLB instance. The supported instance types vary with the region.
internetChargeType Billing method of the SLB instance paybytraffic paybybandwidth and paybytraffic The billing method of the public network SLB instance. If this parameter is set to paybybandwidth, the SLB instance is billed by bandwidth. If this parameter is set to paybytraffic, the SLB instance is billed by traffic.
healthCheckUrl URL for health check N/A

resources.slb.intranet: Internal network SLB configuration

Parameter Configuration item Default value Valid values Description
enable Whether to enable internal network SLB true true and false Specifies whether to enable internal network SLB. If multiple ECS instances exist in the deployment environment, you can create or configure an SLB instance in the SLB console for load balancing.
slbId SLB instance ID The ID of the internal network SLB instance. You can use an existing SLB instance or enable Web+ to purchase an SLB instance.
listenerPort SLB listener port 80 [1, 65535] The listener port of the internal network SLB instance. This port enables you to access the application from the internal network.
protocol SLB protocol http http and tcp The protocol type of the internal network SLB instance.
forwardingRule SLB routing method The routing method of the internal network SLB instance.
bandwidth Peak bandwidth on the listener port -1 [-1, 5120] The peak bandwidth on the listener port.
bandwidth Peak bandwidth on the listener port -1 [-1, 5120] The peak bandwidth on the listener port.
loadBalancerSpec SLB instance type slb.s1.small slb.s1.small, slb.s2.small, slb.s2.medium, slb.s3.small, slb.s3.medium, and slb.s3.large The type of the internal network SLB instance. The supported instance types vary with the region.
internetChargeType Billing method of the SLB instance paybytraffic paybybandwidth and paybytraffic The billing method of the internal network SLB instance. If this parameter is set to paybybandwidth, the SLB instance is billed by bandwidth. If this parameter is set to paybytraffic, the SLB instance is billed by traffic.

resources.rds: RDS configuration

Parameter Configuration item Valid values Default value Description
enable Whether to enable RDS true and false false Specifies whether to enable Relational Database Service (RDS).
imported Whether to use an existing RDS instance true and false false Specifies whether to use an existing RDS instance.
rdsId RDS instance ID Valid RDS instance ID None The ID of the RDS instance to use. To use an existing RDS instance, you must specify this parameter.
zoneId Zone Valid zone ID None The ID of the zone where the RDS instance resides. You can call the DescribeRegions operation of RDS to query available zones.
VSwitches VSwitch list VSwitch ID None The ID of the VSwitch in the zone where the RDS instance resides.
engine Database type MySQL, SQLServer, PostgreSQL, PPAS, and MariaDB None The database type of the RDS instance.
engineVersion Database version MySQL: 5.5, 5.6, 5.7, and 8.0. SQL Server: 2008r2, 2012, 2012_ent_ha, 2012_std_ha, 2012_web, 2016_ent_ha, 2016_std_ha, 2016_web, and 2017_ent. PostgreSQL: 9.4 and 10.0. PPAS: 9.3 and 10.0. MariaDB: 10.3. None The database version of the RDS instance.
storageType Storage type local_ssd/ephemeral_ssd, cloud_ssd, and cloud_essd None The storage type of the RDS instance. A value of local_ssd or ephemeral_ssd indicates the local SSD. A value of cloud_ssd indicates the SSD. A value of cloud_essd indicates the ESSD. Local SSDs are recommended.
storageSize Storage capacity Integer 100 The storage capacity of the RDS instance. Unit: GB.
dbInstanceClass Instance type Valid instance type None The type of the RDS instance. For more information, see the instance types in the ApsaraDB for RDS documentation.
databaseName Database name A string webplus The database name of the RDS instance.
characterSetName Character set name MySQL or MariaDB: utf8, gbk, latin1, and utf8mb4. SQL Server: Chinese_PRC_CI_AS, Chinese_PRC_CS_AS, SQL_Latin1_General_CP1_CI_AS, SQL_Latin1_General_CP1_CS_AS, and Chinese_PRC_BIN. MySQL or MariaDB: utf8mb4. SQL Server: Chinese_PRC_CI_AS. The character set of the RDS instance.
accountName Account name A string webplus The database account name of the RDS instance.
accountPassword Account password A string None The database account password of the RDS instance.
category Category Valid values:
  • Basic: basic edition
  • HighAvailability: high availability edition
  • AlwaysOn: cluster edition
  • Finance: financial edition (supported only in China)
None The family of the RDS instance.

Application

application.option: Service port

Parameter Configuration item Default value Valid values Description
port Service port 8080 [1024, 65535] The service port of the application. After the application is started, it uses this port to provide HTTP services. The port number ranges from 1024 to 65535.

application.healthCheck: Health check configuration

Parameter Configuration item Default value Valid values Description
type Health check type http http and tcp The protocol type to use for health check. Currently, TCP and HTTP are supported. Web+ periodically sends health check requests to the service port of the application to check whether the application is healthy.
retryCount Number of health check retries 3 [1, 30] The maximum number of health check retries. If the number of health check retries exceeds this upper limit, the health check fails.
intervalSeconds Health check interval 3 [1, 60] The interval between a failed health check and the next health check.
timeoutSeconds Health check timeout duration 3 [1, 60] The timeout duration of a health check.

application.commands: Commands

Parameter Configuration item Description
start Start command The command used to start the application.
stop Stop command The command used to stop the application.

hooks: Lifecycle hook

Parameter Configuration item Description
prestart Pre-start command The command to run before the application is started.
poststart Post-start command The command to run after the application is started.
prestop Pre-stop command The command to run before the application is stopped.
poststop Post-stop command The command to run after the application is stopped.
postinit Post-initialization command The command to run after the application is initialized.

application.jvmOpts: JVM configuration

Parameter Configuration item Description
value JVM parameters The Java virtual machine (JVM) parameters used to start the application.

application.enviromentVariables: Environment variables

Parameter Configuration item Description
value Environment variables The environment variables used to start the application.