Due to a default Keystone policy until Newtown, and the use of resource_find, non-admins are unable to list their own projects. This patch bypasses this problem while also introducing better UX for non-admins wishing to get their project list. 'openstack project list' retains the default of 'list all projects' but on a forbidden error will default instead to 'list my projects'. This way for non-admins 'list my projects' feels like the default without breaking the expected admin default. Adding the '--my-projects' option allows admins to easily list their own projects or allows non-admins to be explicit and bypass the forbidden error fallback. Change-Id: I1021276f69fbbf28e13e17c4e567d932fce7ed8b Closes-Bug: #1627555
		
			
				
	
	
		
			10 lines
		
	
	
		
			435 B
		
	
	
	
		
			YAML
		
	
	
	
	
	
			
		
		
	
	
			10 lines
		
	
	
		
			435 B
		
	
	
	
		
			YAML
		
	
	
	
	
	
---
 | 
						|
features:
 | 
						|
  - |
 | 
						|
    The ``project list`` command lists all projects when called by an
 | 
						|
    admin user.  For non-admin users it will now list projects for the
 | 
						|
    authenticated user instead of exiting with an authorization failure.
 | 
						|
    The ``--my-projects`` option has also been added to the ``project list``
 | 
						|
    command to allow admin users to list their own projects.
 | 
						|
    [Bug `1627555 <https://bugs.launchpad.net/bugs/1627555>`_]
 |