Giter VIP home page Giter VIP logo

shinyserver_on_raspberrypi's Introduction

Install Shiny Server on Raspberry Pi with R

If you want to use place a Shiny Server on a Raspberry Pi, 1) yes the RPi can handle it! 2) these scripts will allow you to do it effortlessly. Regarding the performance of a Shiny Server on a Raspberry Pi, the device seems to handle it quite well and I haven't seen significant processing/speed issues.

Contents

Warnings

These scripts are provided "as is" with no warranty of any kind. As such, users should read the script to ensure they are confident in its integrity. The script is well contained and should not interfere with anything on the RPi beyond Shiny Server-related tasks. These have been tested and are known to work as of January 24, 2021.

Important Tasks Solved in the Script

  • Handles system library dependencies for installing and running a Shiny Server
  • Installs all R packages required for Shiny Server to start and index.html to successfully open
  • Edits external/node/install-node.sh to obtain the correct NodeJS installation for a Raspberry Pi
  • Builds Shiny Server via packaging/make-package.sh
  • Configures Shiny Server, sets up initial server applications, and places all the required system directories
  • Resolves Pandoc issues arising from Shiny Server using it's packaged Pandoc distribution by removing this directory and giving the system-installed version precedence

Installation with Stable R

The provided Stable_RPiShinyServer.sh script will install the latest Shiny Server distribution along with the stable R version via the following command (N.B. the script takes awhile to run due to the R library installations):

wget -O - https://raw.githubusercontent.com/pjaselin/ShinyServer_On_RaspberryPi/master/StableInstall_RPiShinyServer.sh | bash

Installation with Backport R

Warning: you may attempt this at your own risk. If you already have R installed, this could remove all previously installed R libraries. If you would like to try using the latest (or later) version of R, you may follow these instructions to point the Raspberry Pi to the required mirrors (N.B. if you would like to upgrade your Raspberry Pi to a newer OS such as the Buster-based version, see here: https://www.raspberrypi.org/documentation/raspbian/updating.md).

Add Secure Apt Key

Sourced from: https://cloud.r-project.org/bin/linux/debian/#secure-apt

sudo apt-get install dirmngr --install-recommends
sudo apt-key adv --keyserver keys.gnupg.net --recv-key 'E19F5F87128899B192B1A2C2AD5F960A256A04AF'
sudo apt-get -y update && sudo apt-get -y upgrade

Add the Branch-Specific Mirror

Sourced from: https://cloud.r-project.org/bin/linux/debian/#supported-branches

For Buster & R 4

echo 'deb http://cloud.r-project.org/bin/linux/debian buster-cran40/' | sudo tee --append /etc/apt/sources.list

For Buster & R 3.6.3

echo 'deb http://cloud.r-project.org/bin/linux/debian buster-cran35/' | sudo tee --append /etc/apt/sources.list

For Stretch & R 3.6.3

echo 'deb http://cloud.r-project.org/bin/linux/debian stretch-cran35/' | sudo tee --append /etc/apt/sources.list

Finally Install Shiny Server and R

wget -O - https://raw.githubusercontent.com/pjaselin/ShinyServer_On_RaspberryPi/master/StableInstall_RPiShinyServer.sh | bash

Uninstall Shiny Server and R

To remove Shiny Server AND R, please run the following command to execute the Uninstall_RPiShinyServer.sh script:

wget -O - https://raw.githubusercontent.com/pjaselin/ShinyServer_On_RaspberryPi/master/Uninstall_RPiShinyServer.sh | bash

If you would only like to remove Shiny Server, please look into this script and only use what you need.

Future Maintenance

I will try to keep this updated as the Shiny Server repo develops. Please submit issues if you run into problems and I'll do my best to make changes to the script as necessary. PRs are also welcome!

shinyserver_on_raspberrypi's People

Contributors

pjaselin avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

shinyserver_on_raspberrypi's Issues

node install checksum failure

It would be good to put a comment in 'Stable_RPiShinyServer.sh' regarding how to modify the patched 'install-node.sh' to update the NODE_SHA256 variable for newer versions.

To get the current checksums to modify the NODE_SHA256 variable, see the Verifying Binaries section in here

Uninstall

Hey; unfortunately I have managed to messed up my installation and would like to do a fresh reinstall. However, as Iā€™m new to setting up servers, Iā€™m not sure where to begin.. Do by any chance you already have an uninstall script? Thank you very much!

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.