Skip to content

Project Import: support for non-admin credentials #459

Description

@ezeriver94

What would you like to see implemented?

Openstack's identity API supports listing own projects using a non-admin account. Making Project actuator able to use both endpoints to produce a list of projects would enable importing projects without using admin credentials (similar to what openstack-cli does).
Currently, ORC uses /v3/projects?filters... when trying to import by filters, and /v3/projects/{ID} when trying to import by ID. If I use non-admin account, only import by ID works; importing by name or other filters will stay forever in "Waiting" status (IMO it should be failing after keystone responds with 403, but maybe this is a bug in gophercloud).
This feature request is for making ORC fallback to listing own projects after an unauthorized (or empty) response.

Additional information

I believe this would require extending provider's scope with UserID (now it has ProjectID only) and retrieving the UserID the same way as the project (from the AuthResult). The drawback is that currently gophercloud's implementation of users.ListProjects does not accept ListOptions, even though the endpoint does, so it should be added to gophercloud too.

Link to reference documentation

https://github.com/gophercloud/gophercloud/blob/main/openstack/identity/v3/users/requests.go#L324

Activity

  1. mandre commented on Jul 7, 2025

    @mandre
    Collaborator

    This is a fair request, and we should indeed avoid requiring admin credentials unless strictly necessary. In this case, we should provide a way for users to list their projects. On the technical side, I'm not clear yet how this would need to be implemented.

  2. zunken1337 commented on Oct 23, 2026

    @zunken1337
    Contributor

    We need this too (non-admin credentials on a public cloud), so I'd like to pick it up. Plan, all in the identity client: if GET /v3/projects returns 403, list the caller's projects with GET /v3/auth/projects (projects.ListAvailable, no gophercloud change needed) and apply the filter client-side (name, domain, tags). Import by ID already works without admin. Checked on our cloud: /v3/projects gives 403 for a project member, /v3/auth/projects returns their projects with tags. Plus a kuttl test importing the demo project with the non-admin credentials. Sounds OK?

  3. added a commit that references this issue on Oct 24, 2026
    4828b72
  4. added a commit that references this issue on Nov 4, 2026
    2c2a60b
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions