4040
4141
4242DESCRIPTION_LIMIT = 20
43- BLUEPRINT_COLUMNS = ['id' , 'description' , 'main_file_name' , 'created_at' ,
44- 'updated_at' , 'visibility' , 'tenant_name' , 'created_by' ]
43+ BASE_BLUEPRINT_COLUMNS = ['id' , 'description' , 'main_file_name' , 'created_at' ]
44+ BLUEPRINT_COLUMNS = BASE_BLUEPRINT_COLUMNS + ['updated_at' , 'visibility' ,
45+ 'tenant_name' , 'created_by' ]
4546INPUTS_COLUMNS = ['name' , 'type' , 'default' , 'description' ]
4647
4748
@@ -210,8 +211,7 @@ def delete(blueprint_id, force, logger, client, tenant_name):
210211 logger .info ('Blueprint deleted' )
211212
212213
213- @blueprints .command (name = 'list' ,
214- short_help = 'List blueprints [manager only]' )
214+ @cfy .command (name = 'list' , short_help = 'List blueprints' )
215215@cfy .options .sort_by ()
216216@cfy .options .descending
217217@cfy .options .common_options
@@ -224,15 +224,15 @@ def delete(blueprint_id, force, logger, client, tenant_name):
224224@cfy .assert_manager_active ()
225225@cfy .pass_client ()
226226@cfy .pass_logger
227- def list (sort_by ,
228- descending ,
229- tenant_name ,
230- all_tenants ,
231- search ,
232- pagination_offset ,
233- pagination_size ,
234- logger ,
235- client ):
227+ def manager_list (sort_by ,
228+ descending ,
229+ tenant_name ,
230+ all_tenants ,
231+ search ,
232+ pagination_offset ,
233+ pagination_size ,
234+ logger ,
235+ client ):
236236 """List all blueprints
237237 """
238238 def trim_description (blueprint ):
@@ -260,6 +260,13 @@ def trim_description(blueprint):
260260 logger .info ('Showing {0} of {1} blueprints' .format (len (blueprints ), total ))
261261
262262
263+ @cfy .command (name = 'list' , short_help = 'List blueprints' )
264+ @cfy .pass_logger
265+ def local_list (logger ):
266+ blueprints = local .list_blueprints ()
267+ print_data (BASE_BLUEPRINT_COLUMNS , blueprints , 'Blueprints:' )
268+
269+
263270@blueprints .command (name = 'get' ,
264271 short_help = 'Retrieve blueprint information [manager only]' )
265272@cfy .argument ('blueprint-id' )
0 commit comments