create-blueprint

Attention

Creating blueprints in a public or private catalog requires the authority to manage the catalog. Refer to the Catalogs section in this document for more information.

The create-blueprint command adds a blueprint to a catalog. What catalog the blueprint is added to is determined by one of the options in the order below:

  1. By specifying the --publicCatalog command argument.
  2. By specifying the desired company catalog with the command argument --catalogid
  3. Otherwise the company catalog associated with the customer of the user running the command is used. The company catalog will be created if it does not exist.

Help

create-blueprint --help
usage: create-blueprint [-h] [--imports IMPORTS] [--imagefile IMAGEFILE]
                        [--groupids GROUPIDS] [--createdby CREATEDBY]
                        [--catalogid CATALOGID] [--publicCatalog]
                        [--not-active-version]
                        templatefile

positional arguments:
  templatefile          Main blueprint template file. Note this file has the
                        "template_name" definition

optional arguments:
  -h, --help            show this help message and exit
  --imports IMPORTS     Delimited list of import files referenced by template
  --imagefile IMAGEFILE
                        Icon image to associate template with
  --groupids GROUPIDS   Optional list of groupIds to associate blueprint with
  --createdby CREATEDBY
                        Optional created by tag for labeling blueprint
  --catalogid CATALOGID
                        Optional catalogId to add blueprint to, defaults to
                        company catalog
  --publicCatalog       Use public catalog
  --not-active-version  Does not set this blueprint as the current active
                        version. Note the default for this command is to set
                        the new blueprint as ActiveVersion

Note

You must specify the base_types.yaml file (this contains the TOSCA Dell Cloud Manager node types, relationships, and capability types which are referenced in the template file). If you have split your blueprint definition into multiple template files, you must also specify each additional template file that makes up your blueprint separated by a comma, in any order.

Example 1

Here is an example of creating a blueprint in the customer company company catalog with an image acme_logo.png

create-blueprint apache_web_server_no_cm.yaml --imports base_types.yaml --imagefile acme_logo.png
Loading API environment
  API access validated
  API access key type is User, userId: 10
Found public catalog, id= 15
Found Company catalog, id= 10
  Defaulting to Company catalog, id: 10
  Including import: "base_types.yaml"
  Including image file: "acme_logo.png"
Adding blueprint to catalog 10, activeVersion=True, name= "Apache Web Server on Linux"
  Added "Apache Web Server on Linux" id: 73 version: 1.00

As soon as the create-blueprint command completes successfully, the blueprint will appear on the Dell Cloud Manager console in the company catalog.

../_images/blueprint_in_company_catalog_on_console.png

Example 2

Here is an example of creating a blueprint in the public catalog with an image joomla.png

create-blueprint joomla_two_server.yaml --imports base_types.yaml --imagefile joomla.png --publicCatalog
Loading API environment
  API access validated
  API access key type is User, userId: 10
  Found public catalog, id= 15
  Found Company catalog, id= 10
  Including import: "base_types.yaml"
  Including image file: "joomla.png"
Adding blueprint to catalog 15, activeVersion=True, name= "Joomla Two Server Stack using Chef"
  Added "Joomla Two Server Stack using Chef" id: 74 version: 1.00

As soon as the create-blueprint command completes successfully, the blueprint will appear on the Dell Cloud Manager console in the public catalog.

../_images/blueprint_in_public_catalog_on_console.png