Hello,
Is there any statement or configuration tweak that would enable the identification of the current user of an application or a document? We tried different strategies, but they all either return "rstudio-connect" or nothing. Examples:
Thank you for the suggestions, but they also return "rstudio-connect". I am afraid that, should a solution exist, it would require some configuration changes.
Do you use the authentication mechanism from within RStudio connect ? That is to say your app is not public and you have to log in as a user to rstudio connect to see the app.
And Have you changed the user who run the application to the identified user ?
You get Sys.getenv("USER") to `rstudio-connect because by default this the unix user that runs all the content unless you say otherwise.
With RStudio connect, you can get information for identified user in the session$user value in a shiny app. You can look at this documentation to know more https://shiny.rstudio.com/articles/permissions.html
This will allow you to have customized application depending on who is consulting it. See some examples:
With this, the application will run on the system (on the server) using an account corresponding to another user, or the identified user directly. This is required if you have some control ressource or control access based on the linux account you want to be used by your app. Otherwise, the previous solution should be the one you are looking for to identify current user with session$user