CCI-MOC / hil

Hardware Isolation Layer, formerly Hardware as a Service
Apache License 2.0
24 stars 54 forks source link

Project related CLI calls #995

Open SahilTikale opened 6 years ago

SahilTikale commented 6 years ago

Following calls are required for project. Should list resources allocated to the project like <node>, <networks>, <users> For Networks it should show which the project owns versus which are shared with the project For Users it should show which are admin vs which are regular

This call should be accessed by administrator and by any user that belongs to the <project>

hil project show <project_name>

For Administrator: Following call should list all projects. For Users: Following call should list all the projects that the user is part of.

hil project list 
zenhack commented 6 years ago

adding a project show sounds good to me.

The admin_only variant of the project list call already exists. I don't like things that have different behavior (besides allow/deny) based on the identity of the caller, so I'm not a fan of extending it for the user case. But we can just get that info from the user show call you suggest in #994, which can either require admin access or being the user in question. I'm vaguely uncomfortable with that design, since we don't otherwise use user as the unit of authentication, just project, but maybe it's okay if it's scoped to the user based auth backend anyway (the call would just not exist when we're not doing users). Not sure how I feel about that.

xuhang57 commented 6 years ago

https://github.com/CCI-MOC/hil/issues/949

zenhack commented 6 years ago

Okay, yeah, looks like this is just a duplicate of #949; I'm going to close it to centralize the discussion.

zenhack commented 6 years ago

Ack, no, it's not quite the same, reopening. Still waking up :/...