Multiple users log into same VM as same "user"

1,497 views
Skip to first unread message

Steve Lorimer

unread,
Nov 29, 2018, 1:19:34 PM11/29/18
to gce-dis...@googlegroups.com
Hi all

I have multiple users connecting to the same VM using ssh.

I've added each user's ~/.ssh/id_rsa.pub file to metadata/ssh keys

They are all able to successfully login, but I'm hitting linux permissions problems when one user creates a file and another attempts to later write to it - as the file is not world writeable, and their user names and/or groups don't match.

How can I allow each user to log into the VM using a private key, but share the same user identity on the VM?

Thanks
Steve

Justin Reiners

unread,
Nov 29, 2018, 1:49:50 PM11/29/18
to Steve Lorimer, gce-dis...@googlegroups.com
add each user to a group, and set permissions with the group involved might work.

--
© 2018 Google Inc. 1600 Amphitheatre Parkway, Mountain View, CA 94043
 
Email preferences: You received this email because you signed up for the Google Compute Engine Discussion Google Group (gce-dis...@googlegroups.com) to participate in discussions with other members of the Google Compute Engine community and the Google Compute Engine Team.
---
You received this message because you are subscribed to the Google Groups "gce-discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to gce-discussio...@googlegroups.com.
To post to this group, send email to gce-dis...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/gce-discussion/CAE-NPOhruabHWf5qiD1RfNsyGU7yR5AAwio%2Bhb1WwGh0%3D8OoyQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Milad (Google Cloud Platform)

unread,
Nov 29, 2018, 8:02:11 PM11/29/18
to gce-discussion
Hello Steve,

If a user presents their private SSH key, then they can use a third-party tool to connect to any instance that is configured with the matching public SSH key file, even if they are not a member of your Cloud Platform project. This article explains how to control access to Linux instances by creating SSH keys and editing public SSH key metadata.

Please note a private SSH key file that the user should stores on their local machines.
Reply all
Reply to author
Forward
0 new messages