Is there a variable or way of querying a running RStudio Shiny webpage to display the version of the server that is running? E.g. display something like shiny-0.10.1
on the webpage.
Any ideas?
Shiny Server is an open source back end program that makes a big difference. It builds a web server specifically designed to host Shiny apps. With Shiny Server you can host your apps in a controlled environment, like inside your organization, so your Shiny app (and whatever data it needs) will never leave your control.
Shiny applications have two components, a user interface object and a server function, that are passed as arguments to the shinyApp function that creates a Shiny app object from this UI/server pair.
R file will be simple — it will source the UI and server files and create the Shiny application using shinyApp() . You'll need to install and load the shiny package. Second, you will need to source the UI and server files.
You can get the version of shiny that is running using packageVersion
:
> packageVersion("shiny")
[1] ‘0.10.1’
If you want details on the server you can do a system call:
> system('shiny-server --version', intern = TRUE)
[1] "Shiny Server v1.1.0.10000" "Node.js v0.10.21"
or if you are running shiny server pro there is a heath check endpoint so calling
http://my-shiny-ip-address/__health-check__
would return a http response with server info if the server is online like:
server-version: 1.2.3.4
active-connections: 8
active-apps: 2
active-processes: 3
cpu-percent: 13
memory-percent: 49
swap-percent: 39.1
load-average: 1.01953125
see http://rstudio.github.io/shiny-server/latest/#monitoring-the-server
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With