Coder Social home page Coder Social logo

rstudio / shiny-server Goto Github PK

View Code? Open in Web Editor NEW
709.0 88.0 291.0 15.23 MB

Host Shiny applications over the web.

Home Page: https://rstudio.com/shiny/server

License: Other

R 2.46% JavaScript 69.38% Shell 6.91% Python 2.61% HTML 8.00% CMake 1.56% C++ 2.29% CSS 0.21% Dockerfile 0.55% Groovy 1.35% TypeScript 4.68%

shiny-server's Introduction

Shiny Server

Shiny Server is a server program that makes Shiny applications available over the web.

Features

  • Host multiple Shiny applications, each with its own URL
  • Can be configured to allow any user on the system to create and deploy their own Shiny applications
  • Supports non-websocket-capable browsers, like IE9
  • Free and open source (AGPLv3 license)
  • Pre-built installers for select Linux distributions.

Installing

At this time, Shiny Server can be run on Linux servers with explicit support for Ubuntu 14.04 or greater (64 bit) and CentOS/RHEL 6 (64 bit) or greater. If you are using one of these distributions, please download the pre-packaged installers from RStudio:

Download Shiny Server Installers.

These installers will provide a majority of the prerequisite software and will provision all the necessary directories for you.

If you are not using one of the explicitly supported distributions, you can still use Shiny Server by building it from source, see the instructions for building from source.

Configuration

Shiny Server will use the default configuration unless an alternate configuration is provided at /etc/shiny-server/shiny-server.conf. Using the default configuration, Shiny Server will look for Shiny apps in /srv/shiny-server/ and host them on port 3838. If you plan to host your apps in this directory, you can either copy an app you've already developed to that location:

sudo cp -R ~/MY-APP /srv/shiny-server/

Or you can copy some or all of the examples provided with the Shiny package. (The location of the R library varies from system to system. You can use the command R -e ".libPaths()" --quiet to print the directory of the R library.) For instance, on Ubuntu, you could execute cp -R /usr/local/lib/R/site-library/shiny/examples/* /srv/shiny-server/.

Now start a web browser and point it to http://<hostname>:3838/APP_NAME/

If the browser is not able to connect to the server, configure your server's firewall to allow inbound TCP connections on port 3838.

To customize any of the above, or to explore the other ways Shiny Server can host Shiny apps, see the Shiny Server Configuration Reference for details on the various ways Shiny Server can be configured.

Documentation & Contact & Support

See the Administrator's Guide to Shiny Server for more complete documentation regarding the setup and management of Shiny Server.

Please direct questions to the Shiny Community discussion board. If you're interested in Professional Support, please look at our commercial Shiny Server Pro product.

shiny-server's People

Contributors

alandipert avatar aronatkins avatar bborgesr avatar blongworth avatar boidolr avatar brooklynbagel avatar daattali avatar danbentley avatar dskard avatar emcrisan avatar fereshtehrs avatar gadenbuie avatar innir avatar jangaraj avatar jcheng5 avatar jeffreyhorner avatar jmcphers avatar jtoloe avatar pyltime avatar siggyf avatar stevenolen avatar trestletech avatar vzemlys avatar wch avatar yeah avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

shiny-server's Issues

cannot Host a Directory of Applications

Hi,

thank you so much for putting together all these great shiny thing.

I have an issue to host the directory under shiny sever.

In my shiny-server.conf, i put the following
server {
listen 3838;
location /model1 {
site_dir /data/model;
log_dir /var/log/shiny-server;
directory_index on;
}
}

The app is working, but i cannot access the files under the directory.
For example, the http://server:3838/model1 ( app link) works,
but i cannot access to any file under the site_dir, or any link as
http://server:3838/model1/test.pdf doesn't work.

Can you help me to solve this issue, or point to the right direction? Thanks.

Also,i notice that, even if i set the listen port to be 3838, everytime the shiny-server log file will show that the app is running at some random port number, e.g. 12345 not 3838.
Is this what shiny-server do, or i need to change some configuration file?

thanks
andy

RHEL init.d script Doesn't Stop, Doesn't Start on Boot.

In RHEL 6.4, the current init.d script we have doesn't start on boot, and doesn't ever stop the process

As configured, it also does not start up the shiny-server process at boot.

(Edit: I had copied in the wrong chunk from my Shell, which has since been restarted -- sorry...)

img @src is set to null if there is no plot

I think if renderPlot() doesn't produce an image, the placeholder HTML img for shiny-bound-output ends up with src="null". Consequently, the browser makes a request for it from the server.

See also: imageOutputBinding in shiny.js

Hardcoded HTTP cdn links prevent running under HTTPS

Running Shiny behind HTTPS redirected from Apache, I found that the images silently failed to load. The Firefox console says 'Blocked loading mixed active content "http://cdn.sockjs.org/sockjs-0.3.min.js"'.
There are several hardcoded links in files under /usr/lib/node_modules/shiny-server and changing these to SocksJS HTTPS download link at https://d1fxtkz8shb9d2.cloudfront.net/sockjs-0.3.min.js resolves the issue for me.

Can it be made easier to switch these links to HTTPS or self-hosted files instead?

socket.onclose is called when a link on a page is clicked

socket.onclose is called when a link on a page is clicked. While this makes sense from the point of handling the socket, as a consequence, the disconnect class is added to body from shiny.js:

  socket.onclose = function() {
    $(document.body).addClass('disconnected');
  };

This is undesirable when the page contains links to download files where the browser typically opens up the file for download, but at the same time disconnect class is on body (which greys out the page).

AFAIK, a workaround for this is to manually add an event for the link in question so that when it is clicked, it removes the disconnect class from body.

Increase or fix process subscription

Get this error when trying to run mocha tests too many times in one session:

  ◦ properly merges data.: (node) warning: possible EventEmitter memory leak detected. 11 listeners added. Use emitter.setMaxListeners() to increase limit.

Trace
at process.EventEmitter.addListener (events.js:160:15)
at process.on.process.addListener (node.js:768:26)
at new AppConfig (/Users/jeff/workspace/shiny-server/lib/config/app-config.js:26:11)
at Context. (/Users/jeff/workspace/shiny-server/test/app-config.js:71:23)
at Test.Runnable.run (/usr/local/lib/node_modules/mocha/lib/runnable.js:211:32)
at Runner.runTest (/usr/local/lib/node_modules/mocha/lib/runner.js:352:10)
at /usr/local/lib/node_modules/mocha/lib/runner.js:398:12
at next (/usr/local/lib/node_modules/mocha/lib/runner.js:278:14)
at /usr/local/lib/node_modules/mocha/lib/runner.js:287:7
at next (/usr/local/lib/node_modules/mocha/lib/runner.js:234:23)
at Object._onImmediate (/usr/local/lib/node_modules/mocha/lib/runner.js:255:5)
at processImmediate as _immediateCallback

Either increase the limit so users don't get this warning, or fix the issue if it needs fixing

Problem with debian startup script

Debian init script

I try to start shiny-server via this but it's completely silent.

~# cp shiny-server /etc/init.d
~# chmod +x /etc/init.d/shiny-server
~# update-rc.d shiny-server defaults
~# /etc/init.d/shiny-server start

But it's completely silent. Even when I do:

~# /etc/init.d/shiny-server foo

I get nothing...

I've installed shiny-server like so:
~# npm install -g shiny-server

Other info that might be useful:

R> packageVersion("shiny")
[1] ‘0.6.0’

R> version$version.string
[1] "R version 3.0.1 (2013-05-16)"

~# uname -a
Linux tatooine 2.6.32-5-amd64 #1 SMP Sun Sep 23 10:07:46 UTC 2012 x86_64 GNU/Linux

~# npm --version
1.2.14

~# node --version
v0.8.22

From the command line shiny-server starts fine...

~# shiny-server
[2013-06-28 12:15:34.118] [INFO] shiny-server - Shiny Server v0.3.5 (Node.js v0.8.22)
[2013-06-28 12:15:34.119] [INFO] shiny-server - Using config file "/usr/local/lib/node_modules/shiny-server/config/default.config"
[2013-06-28 12:15:34.133] [INFO] shiny-server - Starting listener on 0.0.0.0:3838

[wiki] Ubuntu installation instructions wrong, triggering bash syntax errors.

There is an incorrect command in the Wiki page for how to install this software on Ubuntu.

This link has the instructions: https://github.com/rstudio/shiny-server/wiki/Ubuntu-step-by-step-install-instructions

The instructions use this as one of the commands to run: sudo su - -c "R -e \\"install.packages('shiny', repos='http://cran.rstudio.com/')\\"".

It incorrectly escapes the quote, because \\" is interpreted as an escaped \ character followed by a Bash-interpreted " character which means Bash sees sudo su - -c "R -e \" as the command it has to deal with, which triggers a syntax error with everything after that.

To fix this, the command in the instructions needs to be changed to this: sudo su - -c "R -e \"install.packages('shiny', repos='http://cran.rstudio.com/')\""

The modified command correctly escapes the quotes, which will prevent individuals from getting syntax errors on that command in the install guide.

( This was addressed in this question on Ask Ubuntu: http://askubuntu.com/questions/382232/when-trying-to-install-shiny-server-for-r-on-ubuntu-12-04-the-command-in-the-se )

shiny server upstart init script - server doesn't start on boot

Following the Ubuntu 13.04 shiny server install wiki, for me the upstart init script doesn't start shiny server on boot. I changed "start on stopped networking" to "start on started networking" and now shiny server starts on boot.

This issue has happened on two separate installs for me; one on a desktop 13.04 install and one a server 13.04 install on a VPS. Please let me know if you can replicate this behavior.

FreeBSD installation

Hi,

I tried to install shiny-server on FreeBSD 9.1

npm -g --verbose install shiny-server

...
g++ '-D_LARGEFILE_SOURCE' '-D_FILE_OFFSET_BITS=64' '-DBUILDING_NODE_EXTENSION' -I/root/.node-gyp/0.10.12/src -I/root/.node-gyp/0.10.12/deps/uv/include -I/root/.node-gyp/0.10.12/deps/v8/include -fPIC -Wall -Wextra -Wno-unused-parameter -pthread -m64 -O2 -fno-strict-aliasing -fno-tree-vrp -fno-tree-sink -fno-rtti -fno-exceptions -MMD -MF ./Release/.deps/Release/obj.target/posix/src/posix.o.d.raw -c -o Release/obj.target/posix/src/posix.o ../src/posix.cc
../src/posix.cc: In function 'v8::Handlev8::Value GetGroupList(const v8::Arguments&)':
../src/posix.cc:105: error: invalid conversion from 'GetGroupList::result_t_' to 'gid_t_'
../src/posix.cc:105: error: initializing argument 3 of 'int getgrouplist(const char_, gid_t, gid_t_, int_)'
gmake: *_* [Release/obj.target/posix/src/posix.o] Error 1
gmake: Leaving directory `/usr/local/lib/node_modules/shiny-server/build'
....

Regarding the g++ Version used: I tried the FreeBSD patched g++ 4.2.1 & 4.6.3

Gracefully 503

When over capacity, more gracefully give a 503 error rather than stalling. Will be hard to do accurately for all apps, but should be based on a MAX param of the simple scheduler.

shiny-server kindly removes /dev/null

I suspect that this is not something I should be seeing:

[2014-02-28 14:44:38.312] [WARN] shiny-server - Failed to delete log file /dev/null: ENOENT, unlink '/dev/null'

And the reason that shiny-server can't delete /dev/null at 14:44 is that it's managed to do so at an earlier time, with ensuing hilarity.

Shiny server crashes on missing function error in observer

Test case:

require(shiny)
shinyServer(function(input,output){

anObserver <- observe({
functionThatDoesntExist()
})

output$greeting <- renderText({
"Hello, earthling!"
})
})

==> UI.R <==
require(shiny)
shinyUI(textOutput("greeting"))

"The application unexpectedly exited"

Websocket is closed before the sonnection is established
Error in func() : could not find function "functionThatDoesntExit"

No log was produced - I guess shiny crashed before it had a chance to write logs.

Expected behaviour: Shiny server should send an error visible in the client browser, and continue operating.

Building Shiny Server from Source directions have invalid cmake command

The Building Shiny Server from Source page in the wiki contains an invalid cmake command:

cmake --DCMAKE_INSTALL_PREFIX=/usr/local -DPYTHON="$PYTHON" ../

When I attempt to change the value of CMAKE_INSTALL_PREFIX usign this syntax, CMAKE_INSTALL_PREFIX is not honored---it still attempts to install into the default /usr/local. Using only one hyphen in front of "-DCMAKE_INSTALL_PREFIX" instead of two fixed this; i.e.:

cmake -DCMAKE_INSTALL_PREFIX=/usr/local -DPYTHON="$PYTHON" ../

OSX deployment would like web app and launchd templates

For deployment on OSX server a sample webapp and a launchd would be very useful.

/Library/Server/Web/Config/apache2/webapps/com.example.mywebapp.plist

The webapp explains the launchd to load, and calls shiny server. It also makes shiny server available in the Server.App. It can do cluster load balancing and handles mod_proxy

/System/Library/LaunchDaemons/
Launchd plists explain how to start, stop and check daemons (such as shiny-server)

Cache Supplemented AppSpec in config-router

There's no reason to hit the disk to check for local .shiny_app.conf files on every request. These should be cached in a hash as follows:

[original appSpec] --> [enhancedAppSpec]

Note that we'll want a way to prevent these from accumulating over the lifetime of the server. At the very least, we should be able to wipe out the ones that haven't been recently used. Realistically, we should probably have a scheduler kill itself and emit an event when it has no more workers.

X11 not available

Hello,

excitedly I installed shiny server on a debian linux distribution and the examples run. There is a problem, though.

Graphics in my browser on localhost are not being displayed -- it says "X11 not available". It is a red label where the graphic should be.

"dpkg --status libx11-dev" in the linux command line yields that it is correctly installed.
Any ideas where the problem might come from?

Thanks and keep up the good work!

Tobias

downloadHandler doesn't work well with text/html content type

The content of the generated HTML file is just the temp file reference. Changing the content type to text/plain but keeping the code otherwise the same fixes the problem.

The problem is the filter function in SockJSAdapter.R. It doesn't expect the response$content to have the c(file=tmpfile) construction that httpuv now allows.

Check that settings are overridden properly

The changes in this commit (https://github.com/rstudio/shiny-server-pro/commit/01ea26aded680e54a46a50b63507a657be7bdebf) would have broken the tests below. Confirm that the settings inheritance is still handled properly in light of these changes. And update tests.

app-config.js

 1 passing (6 ms)
  3 failing

  1) AppConfig #addLocalConfig properly overrides data.:
     AssertionError: expected 20 to equal 50
      at Object.Assertion.equal (/Users/fereshteh/shiny-server-pro/node_modules/should/lib/should.js:303:10)
      at Context.<anonymous> (/Users/fereshteh/shiny-server-pro/test/app-config-FK.js:69:54)
      at Test.Runnable.run (/usr/local/lib/node_modules/mocha/lib/runnable.js:211:32)
      at Runner.runTest (/usr/local/lib/node_modules/mocha/lib/runner.js:355:10)
      at /usr/local/lib/node_modules/mocha/lib/runner.js:401:12
      at next (/usr/local/lib/node_modules/mocha/lib/runner.js:281:14)
      at /usr/local/lib/node_modules/mocha/lib/runner.js:290:7
      at next (/usr/local/lib/node_modules/mocha/lib/runner.js:234:23)
      at Object._onImmediate (/usr/local/lib/node_modules/mocha/lib/runner.js:258:5)
      at processImmediate [as _immediateCallback] (timers.js:330:15)

  2) AppConfig #addLocalConfig properly merges data.:
     AssertionError: expected 20 to equal 50
      at Object.Assertion.equal (/Users/fereshteh/shiny-server-pro/node_modules/should/lib/should.js:303:10)
      at Context.<anonymous> (/Users/fereshteh/shiny-server-pro/test/app-config-FK.js:94:54)
      at Test.Runnable.run (/usr/local/lib/node_modules/mocha/lib/runnable.js:211:32)
      at Runner.runTest (/usr/local/lib/node_modules/mocha/lib/runner.js:355:10)
      at /usr/local/lib/node_modules/mocha/lib/runner.js:401:12
      at next (/usr/local/lib/node_modules/mocha/lib/runner.js:281:14)
      at /usr/local/lib/node_modules/mocha/lib/runner.js:290:7
      at next (/usr/local/lib/node_modules/mocha/lib/runner.js:234:23)
      at Object._onImmediate (/usr/local/lib/node_modules/mocha/lib/runner.js:258:5)
      at processImmediate [as _immediateCallback] (timers.js:330:15)

  3) AppConfig #addLocalConfig only overrides specific fields.:
     AssertionError: expected 20 to equal 50
      at Object.Assertion.equal (/Users/fereshteh/shiny-server-pro/node_modules/should/lib/should.js:303:10)
      at Context.<anonymous> (/Users/fereshteh/shiny-server-pro/test/app-config-FK.js:121:54)
      at Test.Runnable.run (/usr/local/lib/node_modules/mocha/lib/runnable.js:211:32)
      at Runner.runTest (/usr/local/lib/node_modules/mocha/lib/runner.js:355:10)
      at /usr/local/lib/node_modules/mocha/lib/runner.js:401:12
      at next (/usr/local/lib/node_modules/mocha/lib/runner.js:281:14)
      at /usr/local/lib/node_modules/mocha/lib/runner.js:290:7
      at next (/usr/local/lib/node_modules/mocha/lib/runner.js:234:23)
      at Object._onImmediate (/usr/local/lib/node_modules/mocha/lib/runner.js:258:5)
      at processImmediate [as _immediateCallback] (timers.js:330:15)

Make R Process Killing More Robust

Original bug reported:

OK, so here's what I did:

  1. To make sure that there's no "legacy configuration" issues, I started with a fresh > install of Ubuntu13.04
  2. Install R, shiny, nodejs and shiny-serve according to install procedures on shiny-server website
  3. copy examples folder to shiny-server/www folder
  4. launch shiny server
  5. successively run and close several of the applications in the examples folder
  6. in xterm, type: ps aux so as to see the details of all processes running.

As you continue to run and then close the browser windows, I'm seeing (via ps aux) that there's a growing list of shiny processes persisting. Closing the browser or shutting down shiny-server has no effect---the only way to stop the multiple shiny processes is to manually kill them.

Cannot get the upstart script to load in initctl

The upstart script in /config/upstart does not work for me, even on a clean installation of ubuntu 12.04 and I cannot figure out why. I've checked with plain vanilla install, following the steps in the documentation (i.e. with useradd -r shiny and shiny as user in the default.config file.

The syntax is ok according to init-checkconf, but i cannot get initctl to see the script, neither with initctl reload-configuration nor a full reboot.

Are there any known specific settings for upstart on Ubunut?

EADDR on upstart reload

On Ubuntu 13.04 when issuing sudo reload shiny-server the /var/log/shiny-server.log file fills up with EADDR errors, as if shiny-server is being launched continuously.

[2013-08-09 21:48:38.661] [INFO] shiny-server - Shiny Server v0.4.0 (Node.js v0.10.15)
[2013-08-09 21:48:38.663] [INFO] shiny-server - Using config file "/usr/local/shiny-server/config/default.config"
[2013-08-09 21:48:38.694] [WARN] shiny-server - Running as root unnecessarily is a security risk! You could be running more securely as non-root.
[2013-08-09 21:48:38.697] [INFO] shiny-server - Starting listener on 0.0.0.0:3838
[2013-08-09 21:48:38.698] [INFO] shiny-server - Socket dir: /tmp/shiny-session
[2013-08-09 21:48:38.700] [ERROR] shiny-server - HTTP server error (0.0.0.0:3838): listen EADDRINUSE
[2013-08-09 21:48:38.701] [INFO] shiny-server - Shutting down worker processes
[2013-08-09 21:48:38.932] [INFO] shiny-server - Shiny Server v0.4.0 (Node.js v0.10.15)
[2013-08-09 21:48:38.934] [INFO] shiny-server - Using config file "/usr/local/shiny-server/config/default.config"
[2013-08-09 21:48:38.972] [WARN] shiny-server - Running as root unnecessarily is a security risk! You could be running more securely as non-root.
[2013-08-09 21:48:38.975] [INFO] shiny-server - Starting listener on 0.0.0.0:3838
[2013-08-09 21:48:38.976] [INFO] shiny-server - Socket dir: /tmp/shiny-session
[2013-08-09 21:48:38.978] [ERROR] shiny-server - HTTP server error (0.0.0.0:3838): listen EADDRINUSE
[2013-08-09 21:48:38.979] [INFO] shiny-server - Shutting down worker processes

OSX shiny server (but not standalone) sends NA for unicode

I installed node shiny server (first from npm, then from download of head from here) on OSX server 10.8.3 and after a number of successful fetches and a lot of shiny UI coming up, the application jams up when the web client gets a message consisting solely of "NA". This does not happen for standalone shiny (runApp())

The issue is the transmission of unicode characters in renderTable.

It's not appearing in the shiny trace - must be coming from the node server

Client (safari or chrome) says:

[Error] SyntaxError: JSON Parse error: Unexpected identifier "NA"
dispatchMessage (shiny.js, line 704)
onmessage (shiny.js, line 471)
dispatchEvent (sockjs-0.3.min.js, line 27)
_dispatchMessage (sockjs-0.3.min.js, line 27)
_didMessage (sockjs-0.3.min.js, line 27)
onmessage (sockjs-0.3.min.js, line 27)

To replicate:

==> Server.R <==
require(shiny)
greeting<-scan("greeting","")
shinyServer(function(input,output){
output$greeting<-renderTable({
data.frame(greeting)
})
})

==> UI.R <==
require(shiny)
shinyUI(tableOutput("greeting"))

==> greeting <==
Welcome, the water is 50ºC

problem with scandinavian letters (å,ä,ö)

Hello!

We have installed R, Shiny and Shiny-server on an Ubuntu 13.10-server, and after a lot of configuration we finally got all things to work except one thing:

When we are browsing the shiny-app in a browser it replaces scandinavian letters å and ä with a, and ö with o in the R-scripts. We have saved the R-scripts in UTF-8-format.

It seems to be some kind of encoding-problem somewhere. It works on a local computer using shiny and if we run shiny on the linux-server, but not in shiny-server.

Do you have any idea where we should start looking?

support running shiny server as non-root

In site_dir scenario it should be possible to start shiny-server as a non-root user, e.g. by using systemd, and avoid using su to start workers.

Now shiny-server fails if not started by root. And giving root privileges for a process that doesn't inherently need them (I'm not going to use privileged 80 port either) is not a good security practice.

__assets__ handler doesn't properly use templateDir

Technically, the listener on assets in main.js should render according to a global templateDir directive, if it exists.

This only affects 404 errors within server.com/__assets__/*, though. I can't imagine users would be loading such pages in a browser and needing custom renderings, however. Low priority until we hear otherwise.

log creation for user apps fails when user home directories on NFS with root_squash

When running user apps, I get

[2014-03-03 08:59:42.274] [ERROR] shiny-server - Log directory creation failed: ENOENT, no such file or directory '<home_dir>/ShinyApps/log'

This, I guess, is because shiny server attempts to create these directories as root, but user home directories are, on my system, exported over NFS with the root_squash option, so root can't create files or directories in user directories. The shiny apps are, though, able to run.

If I create the directory ~/ShinyApps/log myself, shiny-server gives me

[2014-03-03 09:16:15.334] [INFO] shiny-server - Error getting worker: Error: EACCES, open '<home_dir>/ShinyApps/log/eric-<user>-20140303-091615-60973.log'
[2014-03-03 09:16:15.335] [ERROR] shiny-server - { [Error: ENOENT, open '<home_dir>/ShinyApps/log/eric-<user>-20140303-091615-60973.log']
  errno: 34,
  code: 'ENOENT',
  path: '<home_dir>/ShinyApps/log/eric-<user>-20140303-091615-60973.log' }
Error: ENOENT, open '<home_dir>/ShinyApps/log/eric-<user>-20140303-091615-60973.log'

and the shiny app is unable to run: with an error page in the browser that says

An error has occurred

The application failed to start.

EACCES, open '<home_dir>/ShinyApps/log/eric-<user>-20140303-091615-60973.log'

Enable gzip compression

Right now it takes quite a long time to load the initial page + static resources, especially over slow connections. I was hoping that somebody could add a feature where shiny could be configured to use gzip when the client indicates Accept-Encoding: gzip.

Unhandled exception when R process unexpectedly exits

Start shiny-server, then run an app. While it is active, sudo killall R. This used to cause Shiny Server to realize the apps had all gone; now you get something like the errors below:

[2013-06-28 17:39:21.808] [ERROR] shiny-server - { [Error: EMFILE, open '/home/jcheng/ShinyApps/log/06_tabsets-jcheng-20130628-173918-80323b65188e.log']
  errno: 20,
  code: 'EMFILE',
  path: '/home/jcheng/ShinyApps/log/06_tabsets-jcheng-20130628-173918-80323b65188e.log' }
Error: EMFILE, open '/home/jcheng/ShinyApps/log/06_tabsets-jcheng-20130628-173918-80323b65188e.log'
[2013-06-28 17:39:26.521] [ERROR] shiny-server - Uncaught exception: TypeError: Cannot read property 'data' of undefined

/home/jcheng/shiny-server-2/lib/main.js:226
  throw err;
        ^
TypeError: Cannot read property 'data' of undefined
    at release (/home/jcheng/shiny-server-2/lib/scheduler/scheduler.js:224:40)
    at SockJSConnection.<anonymous> (/home/jcheng/shiny-server-2/lib/proxy/sockjs.js:87:25)
    at SockJSConnection.EventEmitter.emit (events.js:92:17)
    at Session.didTimeout (/home/jcheng/shiny-server-2/node_modules/sockjs/lib/transport.js:202:23)
    at Session.timeout_cb (/home/jcheng/shiny-server-2/node_modules/sockjs/lib/transport.js:101:22)
    at Timer.listOnTimeout [as ontimeout] (timers.js:110:15)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.