I was trying to host shiny app on an offline Debian VM. So, first, I install R-version 3.1.1 with apt-get on the VM:
$ sudo apt-get update
$ sudo apt-get install r-base
$ sudo apt-get install r-base-dev
Then, I scp all tar.gz files (Including all dependencies) of "shiny" package to the VM from my local and install them successfully with "R CMD ...". After that, I ran the following command to install "gdebi" and used it to install "shiny-server-1.3.0.403-amd64.deb" for shiny server.
$ sudo apt-get install gdebi-core
$ sudo gdebi shiny-server-1.3.0.403-amd64.deb
It returned error at the first time indicating the missing of dependencies:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Building data structures... Done
Building data structures... Done
This package is uninstallable
Dependency is not satisfiable: libssl0.9.8
Then, I followed another post to add the following line to the "etc/apt/sources.list" file and then install the missing dependencies with "apt-get":
deb http://security.ubuntu.com/ubuntu lucid-security main
$ sudo apt-get install libssl0.9.8
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following NEW packages will be installed:
libssl0.9.8
0 upgraded, 1 newly installed, 0 to remove and 26 not upgraded.
Need to get 988 kB of archives.
After this operation, 2,408 kB of additional disk space will be used.
WARNING: The following packages cannot be authenticated!
libssl0.9.8
Install these packages without verification? [y/N] y
Get:1 http://security.ubuntu.com/ubuntu/ lucid-security/main libssl0.9.8 amd64 0.9.8k-7ubuntu8.27 [988 kB]
Fetched 988 kB in 1s (902 kB/s)
Preconfiguring packages ...
Selecting previously unselected package libssl0.9.8.
(Reading database ... 46468 files and directories currently installed.)
Preparing to unpack .../libssl0.9.8_0.9.8k-7ubuntu8.27_amd64.deb ...
Unpacking libssl0.9.8 (0.9.8k-7ubuntu8.27) ...
Setting up libssl0.9.8 (0.9.8k-7ubuntu8.27) ...
Processing triggers for libc-bin (2.19-18+deb8u3) ...
It seems worked and I installed "shiny-server-1.3.0.403-amd64.deb":
$ sudo gdebi shiny-server-1.3.0.403-amd64.deb
Reading package lists... Done
Building dependency tree
Reading state information... Done
Building data structures... Done
Building data structures... Done
Shiny Server
Shiny Server is a server program from RStudio, Inc. that makes Shiny applications available over the web. Shiny is a web application framework for the R statistical computation language.
Do you want to install the software package? [y/N]:y
Selecting previously unselected package shiny-server.
(Reading database ... 46487 files and directories currently installed.)
Preparing to unpack shiny-server-1.3.0.403-amd64.deb ...
Unpacking shiny-server (1.3.0.403) ...
Setting up shiny-server (1.3.0.403) ...
Creating user shiny
grep: /etc/init/shiny-server.conf: No such file or directory
Adding LANG to /etc/init.d/shiny-server, setting to en_US.UTF-8
Yet, when I tried to "stop/start" shiny server from terminal, cli can't recognize the command:
$ sudo stop shiny-server
sudo: stop: command not found
I am wondering whether I installed the server right? How can I "start/stop" shiny-server?
I've been using shiny-server this way on Debian Wheezy but switched to self-compiling when I upgraded to Debian Jessie, since this was the recommended route per RStudio Documentation.
To answer your problem, shiny-server is managed using a init.d script. To start the server you should run /etc/init.d/shiny-server start
or service shiny-server start
as root (sudo).
This is not a Shiny problem, just you are missing the command , stop is an option for the command service
You should use:
sudo service start shiny-server
to start it
sudo service stop shiny-server
to stop it
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.