Shared SSH Workspaces - Getting the logged in user


#1

We are currently using your SSH workspaces, we have one workspace set up per project and are sharing those workspaces with our team. Everything is working brilliantly so far, but we would like to know if the following is possible.

On our server is it possible to get the username of the cloud9 user currently logged into the workspace - so that we may use this in some custom bash scripts etc.

I can see there is a few c9 environment variables created, such as C9_USER but this value is the owner of the workspace and not the current user.

Long shot I think but Is this at all possible?

Thank you.


#2

We do not have any environment variables that specify the currently logged in user, however, if your team create their own workspaces on their own Cloud9 accounts that connect to your SSH server then the C9_USER environment variable will be correct for each of them.