edit-icon download-icon

ALIYUN::SLB::VServerGroup

Last Updated: Jun 13, 2018

The ALIYUN::SLB::VServerGroup type is used to create a virtual server group and add backend servers to the Server Load Balancer instance.

Syntax

  1. {
  2. "Type" : "ALIYUN::SLB::VServerGroup",
  3. "Properties" : {
  4. "VServerGroupName" : String,
  5. "BackendServers" : List,
  6. "LoadBalancerId" : String
  7. }
  8. }

Properties

Name Type Required Update allowed Description Constraint
VServerGroupName string Yes No Name of the virtual server group. N/A
BackendServers list Yes Yes List of ECS instances you want to add. The list can contain a maximum of 20 ECS instances.
LoadBalancerId string Yes No ID of the Server Load Balancer instance. N/A

BackendServers syntax

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

BackendServers properties

Attribute name Type Required Update allowed Description Constraint
ServerId string Yes Yes ECS instance ID. N/A
Port integer Yes Yes ECS port number monitored by the Server Load Balancer instance. Value range: [1, 65535].
Weight integer Yes Yes Weights of the ECS instances in the Server Load Balancer instance. Value range: [0, 100].

Return values

Fn::GetAtt

  • VServerGroupId: ID of the virtual server group.
  • BackendServers: List of backend servers added to the Server Load Balancer instance.

Example

  1. {
  2. "ROSTemplateFormatVersion": "2015-09-01",
  3. "Resources": {
  4. "CreateVServerGroup": {
  5. "Type": "ALIYUN::SLB::VServerGroup",
  6. "Properties": {
  7. "LoadBalancerId": "lb-2zenh4ndwrqg14yt094fg",
  8. "VServerGroupName": "VServerGroup-test",
  9. "BackendServers": [
  10. {
  11. "ServerId": "i-25zskuabf",
  12. "Weight": 20,
  13. "Port": 8080
  14. },
  15. {
  16. "ServerId": "i-25zskuabf",
  17. "Weight": 100,
  18. "Port": 8081
  19. }
  20. ]
  21. }
  22. }
  23. },
  24. "Outputs": {
  25. "VServerGroupId": {
  26. "Value" : {"Fn::GetAttr": ["CreateVServerGroup", "VServerGroupId"]
  27. }
  28. }
  29. }
  30. }
Thank you! We've received your feedback.