Initialize a Web Connection

Share:

Description

Initialize a connection to a web server where Shiny apps are served.

Usage

1
2
webConn(user = NULL, ip = NULL, serverDir = "/srv/shiny-server",
  name = NULL)

Arguments

user

the username to log on to the web server

ip

the IP address of the web server - if NULL, it is assumed that your web server is on the same machine that you are working on

serverDir

the directory where Shiny apps go on the web server - defaults to the default location of /srv/shiny-server

name

the name of the directory in serverDir under which to store the application - if not supplied, it defaults to the name provided in the vdb connection

See Also

webSync

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
library(ggplot2)

vdbConn(tempfile(), autoYes = TRUE)

# make a simple display
d <- divide(iris, by = "Species")
makeDisplay(d, name = "sl_vs_sw",
  panelFn = function(x)
    qplot(Sepal.Width, Sepal.Length, data = x))

## Not run: 
# to sync to a server 'myshinyserver.org' with login 'user'
# need: passwordless ssh for user@myshinyserver.org)
# need: rsync installed on local machine
# (these should both be easy to do with local linux / OS X)

# set up a connection to a shiny server
webConn(user = "hafen", ip = "myshinyserver.org", name = "myapp")

# webSync() uses rsync to sync your local vdb
# to the one on your shiny server pointed to with webConn()
webSync()

# if shiny server is running on the remote on port 3838
# then the VDB will now be viewable at
browseURL("http://myshinyserver.org:3838/myapp")

## End(Not run)

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.