Bug 999363

Summary: openstack-nova: Non-public flavors cannot be seen by 'nova flavor-list'.
Product: Red Hat OpenStack Reporter: Omri Hochman <ohochman>
Component: openstack-novaAssignee: Solly Ross <sross>
Status: CLOSED NOTABUG QA Contact: Ami Jeain <ajeain>
Severity: medium Docs Contact:
Priority: medium    
Version: 3.0CC: dallan, hateya, ndipanov, yeylon
Target Milestone: ---   
Target Release: 4.0   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-09-20 18:54:10 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Omri Hochman 2013-08-21 08:43:08 UTC
openstack-nova: Non-public flavors cannot be seen by 'nova flavor-list'. 

Environment:
-------------
Grizzly Puddle 2013-08-15.1 
openstack-nova-2013.1.3-1

Description:
-------------
When user with admin-role creates a private flavor, he suppose to be able to see that this flavor exist by performing 'nova flavor-list'. And the flavor-list table contains 'Is_Public' column, which in this case suppose to indicate Is_Public=False. 

Steps to reproduce : 
---------------------
[root@puma02 ~]# . ~/keystonerc_admin 
[root@puma02 ~(keystone_admin)]# 
[root@puma02 ~(keystone_admin)]# nova flavor-create test6 6 512 4 2 --is-public=false
+----+-------+-----------+------+-----------+------+-------+-------------+-----------+-------------+
| ID | Name  | Memory_MB | Disk | Ephemeral | Swap | VCPUs | RXTX_Factor | Is_Public | extra_specs |
+----+-------+-----------+------+-----------+------+-------+-------------+-----------+-------------+
| 6  | test6 | 512       | 4    | 0         |      | 2     | 1.0         | False     | {}          |
+----+-------+-----------+------+-----------+------+-------+-------------+-----------+-------------+
[root@puma02 ~(keystone_admin)]# 
[root@puma02 ~(keystone_admin)]# nova flavor-list 
+----+-----------+-----------+------+-----------+------+-------+-------------+-----------+-------------+
| ID | Name      | Memory_MB | Disk | Ephemeral | Swap | VCPUs | RXTX_Factor | Is_Public | extra_specs |
+----+-----------+-----------+------+-----------+------+-------+-------------+-----------+-------------+
| 1  | m1.tiny   | 512       | 0    | 0         |      | 1     | 1.0         | True      | {}          |
| 2  | m1.small  | 2048      | 20   | 0         |      | 1     | 1.0         | True      | {}          |
| 3  | m1.medium | 4096      | 40   | 0         |      | 2     | 1.0         | True      | {}          |
| 4  | m1.large  | 8192      | 80   | 0         |      | 4     | 1.0         | True      | {}          |
| 5  | m1.xlarge | 16384     | 160  | 0         |      | 8     | 1.0         | True      | {}          |
+----+-----------+-----------+------+-----------+------+-------+-------------+-----------+-------------+
[root@puma02 ~(keystone_admin)]# 
[root@puma02 ~(keystone_admin)]# nova flavor-show 6 
+----------------------------+-------+
| Property                   | Value |
+----------------------------+-------+
| name                       | test6 |
| ram                        | 512   |
| OS-FLV-DISABLED:disabled   | False |
| vcpus                      | 2     |
| extra_specs                | {}    |
| swap                       |       |
| os-flavor-access:is_public | False |
| rxtx_factor                | 1.0   |
| OS-FLV-EXT-DATA:ephemeral  | 0     |
| disk                       | 4     |
| id                         | 6     |
+----------------------------+-------+

Comment 2 Solly Ross 2013-09-20 18:54:10 UTC
Closing NOTABUG: that's what the --all flag is for (although I think it may merit some discussion about whether or not the --all flag should be the default option for admins and there should be a --public flag instead)