Network

You can create blueprints that launch servers into an existing VPC (virtual network). In order to do that you need to define a VPC Network node in the blueprint template. You must also define a Port node which links the server(s) defined in your blueprint template to the Network node. Dell Cloud Manager does not create a VPC from the Network definition you define in the blueprint template, the VPC must already exist.

The Network node is defined with a section name, a type and properties.

section name

Example: vpc_network:

type

type: dcm.nodes.Network

properties

The following node properties are supported when defining a Network node in a blueprint template:

  • name - network name
  • networkId - Dell Cloud Manager internal Identifier for the network
  • subnet - subnet name
  • subnetId - Dell Cloud Manager internal Identifier for the subnet
  • cloud - cloud where the network will be created in
  • cloudAccountID - cloud account of the cloud
  • region - region in the cloud where the network will be created in
  • zone - data center in the cloud region where the network will be created in

Note

A Port node is used to link a Server node to a Network node.

Network Example 1

In the example below the network name and subnet are hard coded in the Blueprint template file. You could also define input fields in the template to prompt the Dell Cloud Manager user to enter values for them at launch time and then use the get_input internal function to retrieve and set their values. Refer to Internal functions for more details.

    vpc_network:
      type: dcm.nodes.Network                                                    # This is a Network Node
      properties:
        name: "acme-private-network"                                             # Network name is hardcoded to "acme-private-network"
        subnet: "acme-private-subnet"                                            # Subnet name is hardcoded to "acme-private-subnet"
        ############################################################################################################################################### 
        # Retrieve cloud, cloudAccountId, region and datacenter information from the region_selector
        ############################################################################################################################################### 
        cloud: { get_input: [account_region_zone_selector, cloud] }              # Retrieve the cloud from the AccountRegionSelector 
        cloudAccountId: { get_input: [account_region_zone_selector, accountId] } # Retrieve the cloud account ID from the AccountRegionSelector
        region: { get_input: [account_region_zone_selector, region] }            # Retrieve the region from the AccountRegionSelector 
        zone: { get_input: [account_region_zone_selector, zone] }                # Retrieve the zone from the AccountRegionSelector  

Note

In the example above get_input is an internal function. Refer to Internal functions for more details.

Network Example 2

In the example below the Network networkId and subnetId are specified instead of network name and subnet. The values for networkId and subnetId are retrieved from a Network selector previously defined in the template named network_selector.

    vpc_network:
      type: dcm.nodes.Network                                                    # This is a Network Node
      properties:
        ############################################################################################################################################### 
        # Retrieve networkId and subnetId information from the network_selector
        ############################################################################################################################################### 
        networkId: { get_input: [network_selector, networkId] }                  # Retrieve the network ID from the network_selector 
        subnetId: { get_input: [network_selector, subnetId] }                    # Retrieve the subnet ID from the network_selector 
        ############################################################################################################################################### 
        # Retrieve cloud, cloudAccountId, region and datacenter information from the region_selector
        ############################################################################################################################################### 
        cloud: { get_input: [account_region_zone_selector, cloud] }              # Retrieve the cloud from the AccountRegionSelector 
        cloudAccountId: { get_input: [account_region_zone_selector, accountId] } # Retrieve the cloud account ID from the AccountRegionSelector
        region: { get_input: [account_region_zone_selector, region] }            # Retrieve the region from the AccountRegionSelector 
        zone: { get_input: [account_region_zone_selector, zone] }                # Retrieve the zone from the AccountRegionSelector  

Note

In the example above get_input is an internal function. Refer to Internal functions for more details.

Linking a Server to a Network

    ##################################################################################################################################################
    # This node_template defines a virtual machine named "web_vm" which will host the Apache Web Server
    ##################################################################################################################################################
    web_vm:
      type: dcm.nodes.Server                                                     # This is a Server node 
      properties:                                                 
        name: "apache-server"
        ############################################################################################################################################### 
        # Retrieve cloud, cloudAccountId, region and datacenter information from the region_selector
        ############################################################################################################################################### 
        cloud: { get_input: [account_region_zone_selector, cloud] }              # Retrieve cloud from the AccountRegionSelector
        cloudAccountId: { get_input: [account_region_zone_selector, accountId] } # Retrieve the cloud account ID from the AccountRegionSelector
        region: { get_input: [account_region_zone_selector, region] }            # Retrieve region from the AccountRegionSelector
        zone: { get_input: [account_region_zone_selector, zone] }                # Retrieve zone from the AccountRegionSelector
        ############################################################################################################################################### 
        # Retrieve product information from the product_selector
        ############################################################################################################################################### 
        platform: { get_input: [product_selector, platform] }                    # Retrieve platform from the Product selector
        architecture: { get_input: [product_selector, architecture] }            # Retrieve architecture from the Product selector
        product: { get_input: [product_selector, product] }                      # Retrieve product from the Product selector
        image: { get_input: [product_selector, image] }                          # Retrieve machine from the Product selector
        serverProductId: { get_input: [product_selector, serverProductId] }      # Retrieve server product id from the Product selector

    ###################################################################################################################################################
    # This node_template defines a Virtual Private Cloud Network
    ###################################################################################################################################################            
    vpc_network:
      type: dcm.nodes.Network                                                    # This is a Network Node
      properties:
        ############################################################################################################################################### 
        # Retrieve networkId and subnetId information from the network_selector
        ############################################################################################################################################### 
        networkId: { get_input: [network_selector, networkId] }                  # Retrieve the network ID from the network_selector 
        subnetId: { get_input: [network_selector, subnetId] }                    # Retrieve the subnet ID from the network_selector 
        ############################################################################################################################################### 
        # Retrieve cloud, cloudAccountId, region and datacenter information from the region_selector
        ############################################################################################################################################### 
        cloud: { get_input: [account_region_zone_selector, cloud] }              # Retrieve the cloud from the AccountRegionSelector 
        cloudAccountId: { get_input: [account_region_zone_selector, accountId] } # Retrieve the cloud account ID from the AccountRegionSelector
        region: { get_input: [account_region_zone_selector, region] }            # Retrieve the region from the AccountRegionSelector 
        zone: { get_input: [account_region_zone_selector, zone] }                # Retrieve the zone from the AccountRegionSelector  

    ###################################################################################################################################################
    # This node_template defines a Port
    ###################################################################################################################################################
    port:
      type: dcm.nodes.Port                                                       # This is a Port Node
      requirements:
        - link: vpc_network                                                      # Link this port to the network with the section name of "vpc_network"
        - binding: web_vm                                                        # Bind this port to the server with the section name of "web_vm"

Note

In the example above get_input is an internal function. Refer to Internal functions for more details.

Note

If you will be launching servers in a VPC you will need to specify requirements on the Firewall with a relationship to the VPC network, refer to Example of launching a server in a private network with a firewall requirement on the private network for more information.