R Shiny - Access an App on my Local Machine

孤街浪徒 提交于 2019-12-12 07:35:46

问题


I can not avoid windows at work. As such, I have a second machine that I use to do all of my heavy lifting and data analysis. In an ideal world, I could create a Shiny app and access it from another computer on my work's local network.

The solution that my IT folks proposed was using Remote Desktop, which COULD work, but I don't really want other users locking the machine.

Does anyone have insight as to how I can allow computers on my network to view my Shiny apps? I should have admin rights on my 2nd machine in case I need to tweak a few settings.

EDIT: While my ideal use case is Shiny, I would also want to access other R-based reports like Slidify presentations, compiled R Markdown reports, and perhaps, Gitbooks compiled to stand-alone websites.

Thanks in advance.


回答1:


It should be sufficient to set the host argument to 0.0.0.0 to allow it to broadcast beyond localhost, e.g.

runApp("app_name",host="0.0.0.0",port=3168)

Then you can visit http://machine2DNSname:3168 to see it.



来源:https://stackoverflow.com/questions/24065981/r-shiny-access-an-app-on-my-local-machine

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!