A few things have been irking me with some aspects of Juju's CLI. Here's a few thoughts from a user perspective (well, me as user, YMMV).
The following pain points mainly revolve around commands that operate on a controller rather than a model. eg $ juju login [-c controllername] fred $ juju logout [-c controllername] I really think the -c arg is not that natural here. $ juju login controllername fred $ juju logout controllername seem a lot more natural and also explicit, because.... I know without args, the "current" controller will be used... but it's not in your face what that is without running list-controllers first, and so it's too easy to logout of the wrong controller accidentally. Having positional args solves that. The same would then apply to other controller commands, like eg add-model $ juju add-model mycontroller mymodel One thing that might be an issue for people is if they only have one controller, then $ juju logout or $ juju add-model would just work and requiring a controller name is more typing. But 2 points there: 1. as we move forward, people reasonably have more than one controller on the go at any time, and being explicit about what controller you are wanting to use is a good thing 2. in the one controller case, we could simply make the controller name optional so juju logout just works We already use a positional arg for destroy-controller - it just seems natural to do it everywhere for all controller commands. Anyways, I'd like to see what others think, mine is just the perspective of one user. I'd be happy to do a snap and put it out there to get feedback. -- Another issue - I would really, really like a "juju whoami" command. We used to use juju switch-user without args for that, but now it's gone. When you are staring at a command prompt and you know you have several controllers and different logins active, I really want to just go: $ juju whoami Currently active as fred@controller2 Just to get a quick reminder of what controller I am operating on and who I am logged in as on the controller. I know we have a way of doing that via list controllers, but if there's a few, or even if not, you still need to scan your eyes down a table and look for the one wit the * to see the current one and then scan across and get see the user etc. It's all a lot harder than just a whoami command IMO. -- We will need a juju shares command to show who has access to a controller, now that we have controller permissions login, addmodel, superuser. For models, we support: $ juju shares -m model $ juju shares (for the default model) What do we want for controller shares? $ juju shares-controller ? which would support positional arg $ juju shares-controller mycontroller ? -- On the subject of shares, the shares command shows all users with access to a model (or soon a controller as per above). That's great for admins to see who they are sharing their stuff with. What I'd like as a user is a command to tell me what level of access I have to various controllers and models. I'd like this in list-controllers and list-models. $ juju list-controllers CONTROLLER MODEL USER CLOUD/REGION ACCESS fredcontroller* foo fred@local addmodel ian default admin@local lxd/localhost superuser $ juju list-models MODEL OWNER STATUS ACCESS LAST CONNECTION foo* fred@local available write 5 minutes ago The above would make it much easier to see if I could add a model or deploy an application etc. And I don't get to see who else has access like with juju shares, just my own access levels. Thoughts? -- Juju-dev mailing list [email protected] Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/juju-dev
