You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Our admin user has full shell access to every workspace, letting them steal secrets and manipulate workspaces at will. We have clear instructions from our customers that this is a Big Bad. Our major deployments will disable the existing admin users and will want a lesser admin role.
Definition of done
There is a lesser role than the current admin role, without the ability to enter the workspace's terminals. The current admin role is renamed to something more specific.
Suggestions
I propose we rename "admin" to "root" or "deployer". I prefer "root" since everyone knows you're not supposed to use "root", except transiently. Everyone also knows "root" is dangerous.
There is some precedent for this pattern in GitHub Enterprise, which has a special deployer access panel that is not associated with any user.
Some organizations might prefer to deploy with a single "root" user that has the "admin" role, and everyone else, even people who operate the coder deployment day to day have a less powerful role, but I don't think it's universal. We don't currently have the concept of "sudo" in our API, CLI, or Web UI, so it's adding a lot more friction if the operators need to log out and log back in as root to do stuff.
@ammario do you also think we should add an admin role that is different than root?
We can limit the admin role.
Yes. It's unnecessary for MVP but if it's an easy add might as well.
I think it's useful to draw a distinction between roles and users here. "root" is a user, and in our system today, "admin" is a role.
I'm proposing root as a role and not a user. I understand it's a user in Linux. It's easier on the user if we reuse our concept of role instead of creating a new concept of sacred users. If we want to restrict these powers to one user, we could make a special rule around the role that when it's assigned the other assignee is deauthorized.
Some organizations might prefer to deploy with a single "root" user that has the "admin" role, and everyone else, even people who operate the coder deployment day to day have a less powerful role, but I don't think it's universal. We don't currently have the concept of "sudo" in our API, CLI, or Web UI, so it's adding a lot more friction if the operators need to log out and log back in as root to do stuff.
The people who operate the deployment day-to-day will probably use a lesser role based on our current customer behavior. There is friction of logging out and in. The GitHub Enterprise management console has the same problem. A "sudo" could help but I can't think of a product that does that, probably because people don't need god powers that frequently.
If root is a role and not a user, then I don't think I understand how we're proposing this gets used. Can you provide a worked example of what users would exist and what role(s) they would have?
For example
User
Roles
Description
danni
member
Danni is a developer who creates workspaces and nothing else
oscar
???
Oscar is on the dev tools team and manages the coder deployment
If root is a role and not a user, then I don't think I understand how we're proposing this gets used. Can you provide a worked example of what users would exist and what role(s) they would have?
What I have in mind is the first user is given this root role instead of admin. The MVP is just a rename of the "admin" role, a change to a string constant. As a follow-up, we could create a lesser admin role. Perhaps admin can update, stop and delete workspaces but not shell into them. We should discuss the ideal admin role elsewhere though.
By first user I mean the one generated by coderd on startup. It is standard for a product's first user to be given god powers. I can't think of a product that doesn't do that.
Is it standard for that first user login to not be an actual person?
Like, if I, Spike, am setting up a coder deployment, do I name that first user "Spike" and have it be my actual username going forward? If so, then giving it a role called root feels wrong for exactly the reason that it feels dangerous.
If I'm not expected to name it "Spike", and it has god powers that I shouldn't use, then why don't we just name it "root" automatically?
Cloud services like GitHub tend to go with a role called "Owner" for the person who sets things up. I've never seen anything indicating that Owner is dangerous in docs or the site.
@spikecurtis GitHub's self-installed Enterprise has a Management Console with god-like powers. You can even SSH into the instance. God is far more dangerous in Coder than in applications like GitHub. In Coder, you can steal everyone's secrets and impersonate them.
As for the name of the first user, if we go down the root role route then making sure it's named root or similar makes sense.
owner can mean the same thing, but it seems less dangerous and is typically a role you would wear on your main user.
Maybe we should take a step back and consider if we should give any user, no matter how thoroughly authorized, the ability to view everyone's secrets.
I like the idea of keeping the regular old admin user but only giving them super powers if they do the equivalent of sudo. It would be either time or operation limited and come with a scary banner or CLI colors or what have you.
A "sudo" could help but I can't think of a product that does that, probably because people don't need god powers that frequently.
This doesn't make sense to me. It seems like the logic would go the other way. If you need god powers infrequently, the added step would be little issue. If you need them frequently, then you'd dislike the extra step every time.
They don't use the exact same terminology, but Rippling has a mode switch between regular user and admin mode.
This seems like something that should get customer input. We're relying too much on our own opinions here.
I like that suggestion @Emyrk. we make stronger warnings now, but leave god-mode admin labelled as admin. and then in the future when we have more better representative roles for things, admin is really only there for the initial setup and nobody else has full admin and it's not recommended to be used, ever.
@mark-theshark just cited a customer concern with our god-mode admin. Whether or not we rename the roles, we should add the lesser role soon since it's easy.
I have no idea what to call this lesser role other than admin. We could use "superadmin" or "owner" for the root role.
There doesn't seem to be consensus on the admin role. However, I think we can make steps towards a solution by creating roles for the things we create admin users for.
For example, it might be a good idea to have a "template-manager" role added that can create and edit all templates site wide. So we don't need to promote users to "admin" to get that functionality.
There doesn't seem to be consensus on the admin role.
God mode: full access to everything under the sun
Admin: can't shell into other users stuff, but can crud users, templates, workspaces, and has control over all deployment settings
Template admin: site-wide template management ability.
Last question. We have User admin, Template Admin, and the god Owner. The 1 thing lacking, is that only an Owner can promote other users to various roles.
What role should be able to give the User/Template admin role so that we don't need any Owners? Should we just allow User Admins to give the roles? Which means they are also effectively Template Admins?
Activity
Emyrk commentedon Jun 7, 2022
@ammario do you also think we should add an
adminrole that is different thanroot?We can limit the
adminrole.spikecurtis commentedon Jun 7, 2022
I think it's useful to draw a distinction between roles and users here. "root" is a user, and in our system today, "admin" is a role.
spikecurtis commentedon Jun 7, 2022
Some organizations might prefer to deploy with a single "root" user that has the "admin" role, and everyone else, even people who operate the coder deployment day to day have a less powerful role, but I don't think it's universal. We don't currently have the concept of "sudo" in our API, CLI, or Web UI, so it's adding a lot more friction if the operators need to log out and log back in as root to do stuff.
ammario commentedon Jun 7, 2022
Yes. It's unnecessary for MVP but if it's an easy add might as well.
I'm proposing
rootas a role and not a user. I understand it's a user in Linux. It's easier on the user if we reuse our concept of role instead of creating a new concept of sacred users. If we want to restrict these powers to one user, we could make a special rule around the role that when it's assigned the other assignee is deauthorized.The people who operate the deployment day-to-day will probably use a lesser role based on our current customer behavior. There is friction of logging out and in. The GitHub Enterprise management console has the same problem. A "sudo" could help but I can't think of a product that does that, probably because people don't need god powers that frequently.
spikecurtis commentedon Jun 7, 2022
If
rootis a role and not a user, then I don't think I understand how we're proposing this gets used. Can you provide a worked example of what users would exist and what role(s) they would have?For example
ammario commentedon Jun 7, 2022
What I have in mind is the first user is given this
rootrole instead ofadmin. The MVP is just a rename of the "admin" role, a change to a string constant. As a follow-up, we could create a lesser admin role. Perhaps admin can update, stop and delete workspaces but not shell into them. We should discuss the ideal admin role elsewhere though.spikecurtis commentedon Jun 7, 2022
I feel like this conflicts with:
ammario commentedon Jun 7, 2022
By first user I mean the one generated by coderd on startup. It is standard for a product's first user to be given god powers. I can't think of a product that doesn't do that.
spikecurtis commentedon Jun 7, 2022
Is it standard for that first user login to not be an actual person?
Like, if I, Spike, am setting up a coder deployment, do I name that first user "Spike" and have it be my actual username going forward? If so, then giving it a role called root feels wrong for exactly the reason that it feels dangerous.
If I'm not expected to name it "Spike", and it has god powers that I shouldn't use, then why don't we just name it "root" automatically?
spikecurtis commentedon Jun 7, 2022
Cloud services like GitHub tend to go with a role called "Owner" for the person who sets things up. I've never seen anything indicating that Owner is dangerous in docs or the site.
OTOH, AWS has a "management account" with godlike powers and actively dissuades people from using it in everyday life: https://docs.aws.amazon.com/organizations/latest/userguide/orgs_best-practices_mgmt-acct.html
ammario commentedon Jun 7, 2022
@spikecurtis GitHub's self-installed Enterprise has a Management Console with god-like powers. You can even SSH into the instance. God is far more dangerous in Coder than in applications like GitHub. In Coder, you can steal everyone's secrets and impersonate them.
As for the name of the first user, if we go down the
rootrole route then making sure it's namedrootor similar makes sense.ownercan mean the same thing, but it seems less dangerous and is typically a role you would wear on your main user.ketang commentedon Jun 8, 2022
Maybe we should take a step back and consider if we should give any user, no matter how thoroughly authorized, the ability to view everyone's secrets.
I like the idea of keeping the regular old admin user but only giving them super powers if they do the equivalent of sudo. It would be either time or operation limited and come with a scary banner or CLI colors or what have you.
This doesn't make sense to me. It seems like the logic would go the other way. If you need god powers infrequently, the added step would be little issue. If you need them frequently, then you'd dislike the extra step every time.
They don't use the exact same terminology, but Rippling has a mode switch between regular user and admin mode.
This seems like something that should get customer input. We're relying too much on our own opinions here.
8 remaining items
tjcran commentedon Jun 13, 2022
I like that suggestion @Emyrk. we make stronger warnings now, but leave god-mode admin labelled as admin. and then in the future when we have more better representative roles for things, admin is really only there for the initial setup and nobody else has full admin and it's not recommended to be used, ever.
ammario commentedon Jun 30, 2022
@mark-theshark just cited a customer concern with our god-mode admin. Whether or not we rename the roles, we should add the lesser role soon since it's easy.
I have no idea what to call this lesser role other than admin. We could use "superadmin" or "owner" for the root role.
[-]Rename "admin" role to "root"[/-][+]Create lesser admin role[/+]ammario commentedon Jul 21, 2022
I believe this is too basic to be considered enterprise. Most deployments with >10 users will want this.
Emyrk commentedon Aug 12, 2022
There doesn't seem to be consensus on the admin role. However, I think we can make steps towards a solution by creating roles for the things we create admin users for.
For example, it might be a good idea to have a "template-manager" role added that can create and edit all templates site wide. So we don't need to promote users to "admin" to get that functionality.
Opinions? @spikecurtis @ammario @ketang
#3490
tjcran commentedon Aug 12, 2022
God mode: full access to everything under the sun
Admin: can't shell into other users stuff, but can crud users, templates, workspaces, and has control over all deployment settings
Template admin: site-wide template management ability.
@Emyrk does that seem reasonable?
ammario commentedon Aug 12, 2022
I spoke with @Emyrk and @f0ssel about this, and we decided on this matrix:
PR by @Emyrk incoming...
Emyrk commentedon Aug 16, 2022
Last question. We have
User admin,Template Admin, and the godOwner. The 1 thing lacking, is that only anOwnercan promote other users to various roles.What role should be able to give the
User/Templateadmin role so that we don't need anyOwners? Should we just allowUser Adminsto give the roles? Which means they are also effectivelyTemplate Admins?@bpmct @tjcran
ammario commentedon Aug 16, 2022
@Emyrk — Let's stick with the owner managing roles for now.