Blueprint properties, attributes, and parameters

Blueprint properties, attributes, and parameters store information that is used in provisioning cloud environments.

Properties

Most blueprint resources can have one or more properties. These properties are input values that are specified at or before provisioning time. Blueprint properties provide information about the resources. For example, the following code shows a server node. It has several properties, including the ID of the image and the name of the node.
web-server:
  type: OS::Nova::Server
  properties:
    flavor: "small"
    image: "14243a29-9662-4b9d-b164-67884876fc91"
    key_name: "my_key"
    name: "web-server"
    availability_zone: "my_zone"

For more information about using properties in blueprints, see Externalizing properties in blueprints. To limit the valid values for parameters, see Adding constraints to blueprint properties and parameters.

Parameters

Each blueprint begins with a list of parameters. You can specify these parameters in the blueprint, in a configuration file, or at provisioning time. For example, the following code lists the parameter flavor, which represents the size of a provisioned image, and the parameter key_name, which represents the security key for a provisioned image.
parameters:
  flavor:
    type: string
    description: Flavor to be used for compute instance
    default: "m1.small"
  key_name:
    type: string
    description: Name of key-pair to be used for compute instance
    default: "MyKey"
To refer to these parameters in other places in the blueprint, use the get_param function. For example, the following code shows a server node. The properties for the node refer to the parameters in the previous example.
web-server:
  type: OS::Nova::Server
  properties:
    flavor: { get_param: flavor }
    image: "14243a29-9662-4b9d-b164-67884876fc91"
    key_name: { get_param: key_name }
    name: "web-server"

When you provision environments from the blueprint, the parameters appear in the provisioning window. In that window, you can accept the values in the source code or specify new values. To limit the valid values for parameters, see Adding constraints to blueprint properties and parameters.

Attributes

Attributes are output values that are available after provisioning. Attributes are commonly used to provide relevant derived values, such as the IP address of a provisioned instance. For an example of using attributes, see Referring to blueprint properties, attributes, and parameters.

For information on referring to properties, attributes, and parameters, see Externalizing properties in blueprints.


Feedback