Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# No log files
*.log
21 changes: 21 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
FROM rocker/shiny-verse
MAINTAINER Colin Fleming <[email protected]>

# configure environment variable
# note: move this to three ARG commands when CircleCI updates their docker
ENV DCAF_DIR=/usr/src/app \
SHINY_DIR=/srv/shiny-server

# get our gem house in order
RUN mkdir -p ${DCAF_DIR}
WORKDIR ${DCAF_DIR}
COPY packages.R ${DCAF_DIR}/packages.R

# install packages
RUN Rscript packages.R

# Move the rest of the app over
COPY . ${DCAF_DIR}
COPY App/ ${SHINY_DIR}

EXPOSE 3838
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,8 @@
DARIA analytics, but shiny

This R shiny app takes a .csv from DARIA and provides analytics based off that.

## Firing it up

* `docker-compose up`
* http://localhost:3838
11 changes: 11 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
version: '3.1'
services:
shiny:
build:
context: .
dockerfile: Dockerfile
ports:
- "3838:3838"
volumes:
- ./log:/var/log/shiny-server
- ./App:/srv/shiny-server
Empty file added log/.keep
Empty file.
7 changes: 7 additions & 0 deletions packages.R
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Shiny is implied thanks to our Docker image
# So are the tidyverse suite of packages - https://www.tidyverse.org/packages/
pkgs = c(
'highcharter'
)

install.packages(pkgs, quiet=TRUE)