update-blueprint-activeversion

The update-blueprint-activeversion command updates the active version flag on a blueprint. You can use the command to mark a blueprint version as active or inactive. What catalog the blueprint exists in 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.

Help

update-blueprint-activeversion -h
usage: update-blueprint-activeversion [-h] [--active] [--not-active]
                                      [--catalogid CATALOGID]
                                      [--publicCatalog]
                                      blueprintid

positional arguments:
  blueprintid           Blueprint ID

optional arguments:
  -h, --help            show this help message and exit
  --active              Sets this Blueprint as the Active Version
  --not-active          Unsets this Blueprint as the Active Version
  --catalogid CATALOGID
                        Optional catalogId to update blueprint for, defaults
                        to company catalog
  --publicCatalog       Use public catalog

Example 1

The following versions of the blueprint Docker Apache Server on Linux exist in Dell Cloud Manager. The blueprint with Id 35 (Version 2.00) is currently active.

list-blueprint-versions 32
+----+--------+-------------------------------+---------+---------------+------------------------------+------------------------------+
| Id | Parent | Name                          | Version | ActiveVersion | Created                      | Updated                      |
+----+--------+-------------------------------+---------+---------------+------------------------------+------------------------------+
| 32 | 32     | Docker Apache Server on Linux | 1.00    | False         | 2015-09-04T17:28:12.816+0000 | 2015-09-04T17:28:23.132+0000 |
| 33 | 32     | Docker Apache Server on Linux | 1.01    | False         | 2015-09-04T17:28:23.132+0000 | 2015-09-04T17:28:36.866+0000 |
| 34 | 32     | Docker Apache Server on Linux | 1.03    | False         | 2015-09-04T17:28:36.866+0000 | 2015-09-04T17:29:23.327+0000 |
| 35 | 32     | Docker Apache Server on Linux | 2.00    | True          | 2015-09-04T17:29:23.327+0000 | None                         |
+----+--------+-------------------------------+---------+---------------+------------------------------+------------------------------+

To make the version 1.03 of the Docker Apache Server on Linux blueprint in the public catalog active, the following command can be issued:

update-blueprint-activeversion --active --publicCatalog 34
Loading API environment
  API access validated
  API access key type is User, userId: 10
  Found public catalog, id= 15
  Found Company catalog, id= 10
Update id: 34 ActiveVerson: True
Updated id: 34 name='Docker Apache Server on Linux'

Listing all of the versions of that blueprint now shows the blueprint with Id 34 is active.

list-blueprint-versions 32
Loading API environment
  API access validated
  API access key type is User, userId: 10
  Found public catalog, id= 15
  Found Company catalog, id= 10

Number of Blueprints found: 4

+----+--------+-------------------------------+---------+---------------+------------------------------+------------------------------+
| Id | Parent | Name                          | Version | ActiveVersion | Created                      | Updated                      |
+----+--------+-------------------------------+---------+---------------+------------------------------+------------------------------+
| 32 | 32     | Docker Apache Server on Linux | 1.00    | False         | 2015-09-04T17:28:12.816+0000 | 2015-09-04T17:28:23.132+0000 |
| 33 | 32     | Docker Apache Server on Linux | 1.01    | False         | 2015-09-04T17:28:23.132+0000 | 2015-09-04T17:28:36.866+0000 |
| 34 | 32     | Docker Apache Server on Linux | 1.03    | True          | 2015-09-04T17:28:36.866+0000 | 2015-09-04T18:12:14.804+0000 |
| 35 | 32     | Docker Apache Server on Linux | 2.00    | False         | 2015-09-04T17:29:23.327+0000 | 2015-09-04T18:12:14.804+0000 |
+----+--------+-------------------------------+---------+---------------+------------------------------+------------------------------+

Example 2

To make version 1.03 of the Docker Apache Server on Linux blueprint in the public catalog inactive, the following command can be issued:

update-blueprint-activeversion --not-active --public 34
Loading API environment
  API access validated
  API access key type is User, userId: 10
  Found public catalog, id= 15
  Found Company catalog, id= 10
Update id: 34 ActiveVerson: False
Updated id: 34 name='Docker Apache Server on Linux'

Listing all of the versions of that blueprint now shows none of the versions are active and therefore this blueprint can no longer be launched. It will not be displayed in the public catalog in the Dell Cloud Manager console and it cannot be launched using the launch-stack command.

list-blueprint-versions 32
Loading API environment
  API access validated
  API access key type is User, userId: 10
  Found public catalog, id= 15
  Found Company catalog, id= 10

Number of Blueprints found: 4

+----+--------+-------------------------------+---------+---------------+------------------------------+------------------------------+
| Id | Parent | Name                          | Version | ActiveVersion | Created                      | Updated                      |
+----+--------+-------------------------------+---------+---------------+------------------------------+------------------------------+
| 32 | 32     | Docker Apache Server on Linux | 1.00    | False         | 2015-09-04T17:28:12.816+0000 | 2015-09-04T17:28:23.132+0000 |
| 33 | 32     | Docker Apache Server on Linux | 1.01    | False         | 2015-09-04T17:28:23.132+0000 | 2015-09-04T17:28:36.866+0000 |
| 34 | 32     | Docker Apache Server on Linux | 1.03    | False         | 2015-09-04T17:28:36.866+0000 | 2015-09-04T18:28:12.057+0000 |
| 35 | 32     | Docker Apache Server on Linux | 2.00    | False         | 2015-09-04T17:29:23.327+0000 | 2015-09-04T18:12:14.804+0000 |
+----+--------+-------------------------------+---------+---------------+------------------------------+------------------------------+