Last active
September 16, 2020 13:11
-
-
Save HanjoStudy/07c87ada889bc1880ac5831f8c67d0bf to your computer and use it in GitHub Desktop.
Shiny Proxy Server Setup
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
proxy: | |
port: 8080 | |
authentication: simple | |
admin-groups: admins | |
users: | |
- name: jack | |
password: password | |
groups: admins | |
- name: jeff | |
password: password | |
docker: | |
internal-networking: true | |
specs: | |
- id: 01_hello | |
display-name: Hello Application | |
description: Application which demonstrates the basics of a Shiny app | |
container-cmd: ["R", "-e", "ShinyProxy::run_01_hello()"] | |
container-image: openanalytics/ShinyProxy-demo | |
container-network: sp-example-net | |
- id: 06_tabsets | |
container-cmd: ["R", "-e", "ShinyProxy::run_06_tabsets()"] | |
container-image: openanalytics/ShinyProxy-demo | |
container-network: sp-example-net | |
logging: | |
file: | |
ShinyProxy.log |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM openjdk:8-jre | |
RUN mkdir -p /opt/shinyproxy/ | |
RUN wget https://www.shinyproxy.io/downloads/shinyproxy-2.3.0.jar -O /opt/shinyproxy/shinyproxy.jar | |
COPY application.yml /opt/shinyproxy/application.yml | |
WORKDIR /opt/shinyproxy/ | |
CMD ["java", "-jar", "/opt/shinyproxy/shinyproxy.jar"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo docker network create sp-example-net | |
docker build -t mon_shinyproxy . | |
# remember to check whether you have openanalytics/ShinyProxy-demo image | |
sudo docker run -d \ | |
--name shinyproxy \ | |
-v /var/run/docker.sock:/var/run/docker.sock \ | |
-v application.yml:/opt/shinyproxy/application.yml | |
--net sp-example-net \ | |
-p 127.0.0.01:8080:8080 \ | |
mon_shinyproxy |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo apt install default-jre default-jdk | |
sudo apt update | |
sudo apt install apt-transport-https ca-certificates curl software-properties-common | |
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add - | |
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable" | |
sudo apt update | |
sudo apt-get install docker-ce | |
sudo usermod -aG docker ${USER} | |
su - ${USER} | |
sudo docker pull openanalytics/shinyproxy-demo | |
sudo vim /lib/systemd/system/docker.service | |
ExecStart=/usr/bin/dockerd -H fd:// -D -H tcp://127.0.0.1:2375 | |
sudo systemctl daemon-reload | |
sudo systemctl restart docker | |
sudo systemctl status docker |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment