edit-icon download-icon

ALIYUN::SLB::LoadBalancerClone

Last Updated: Jun 13, 2018

The ALIYUN::SLB::LoadBalancerClone type is used to clone a Server Load Balancer instance.

Syntax

  1. {
  2. "Type" : "ALIYUN::SLB::LoadBalancerClone",
  3. "Properties" : {
  4. "SourceLoadBalancerId" : String,
  5. "BackendServersPolicy" : String
  6. }
  7. }

Properties

Name Type Required Description Constraint
SourceLoadBalancerId string Yes ID of the Server Load Balancer instance you want to clone. N/A
BackendServersPolicy. string No Cloning policy, which specifies the ECS instances listened by the new Server Load Balancer instance and the weight of each ECS instance. Value options: clone, empty, append, and replace. The default value is “clone”.
  • clone: The ECS instances listened by the source Server Load Balancer instance and the instance weights are cloned to the new Server Load Balancer instance.
  • empty: no ECS instance is added to the new Server Load Balancer instance.
  • append: The ECS instances listened by the source Server Load Balancer instance and the instance weights are cloned to the new Server Load Balancer instance, and new ECS instances and weights are also added to the new Server Load Balancer instance.
  • replace: New ECS instances and weights are added to the new Server Load Balancer instance, but the ECS instances listened by the source Server Load Balancer instance and the instance weights are not cloned to the new Server Load Balancer instance.
BackendServers list No List of new ECS instances that are listened. N/A
LoadBalancerName string No Name of the Server Load Balancer instance. The value is a custom string. The instance name can contain up to 80 characters including English letters, numbers, hyphens(-), slashes(/), periods(.), and underscores(_).

BackendServers syntax

  1. "BackendServers" : [
  2. {
  3. "ServerId" : String,
  4. "Weight" : Integer
  5. }
  6. ]

BackendServers properties

Name Type Required Description Constraint
ServerId string Yes ECS instance ID. The ECS instance must be in the running state.
Weight integer Yes Weight of the ECS instance in the Server Load Balancer instance. Value range: [0, 100]. Default value: 100.

Return values

Fn::GetAtt

LoadBalancerId: The ID of the new load balancer generated.

Example

  1. {
  2. "ROSTemplateFormatVersion" : "2015-09-01",
  3. "Resources" : {
  4. "CloneLoadBalance": {
  5. "Type": "ALIYUN::SLB::LoadBalancerClone",
  6. "Properties": {
  7. "SourceLoadBalancerId": "150ebed5f06-cn-beijing-btc-a01",
  8. "LoadBalancerName": "rosnew",
  9. "BackendServersPolicy": "replace",
  10. "BackendServers": [
  11. {
  12. "ServerId": "i-25zskuabf",
  13. "Weight": 20
  14. }
  15. ]
  16. }
  17. }
  18. },
  19. "Outputs": {
  20. "LoadBalanceDetails": {
  21. "Value" : {"Fn::GetAtt": ["CloneLoadBalance", "LoadBalancerId"]}
  22. }
  23. }
  24. }
Thank you! We've received your feedback.