-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix #59 - adds shiny-tempo.Rmd and a simple shiny-server to display it
- Loading branch information
Bosse Nyström
committed
Nov 21, 2021
1 parent
e94a8a7
commit 3315da3
Showing
8 changed files
with
45 additions
and
13 deletions.
There are no files selected for viewing
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
# base image | ||
FROM docker.io/rocker/shiny-verse:latest | ||
|
||
|
||
## create directories | ||
RUN mkdir -p /packages | ||
|
||
## copy files | ||
COPY install_packages.R /packages/install_packages.R | ||
|
||
## install R-packages | ||
RUN Rscript /packages/install_packages.R |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
install.packages("slider") |
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,37 @@ | ||
#!/bin/sh | ||
#!/bin/sh -e | ||
|
||
pushd $(dirname ${0}) | ||
SHINY_DOCS="tempo.html" | ||
TEMPO_DOCS="tempo.html" | ||
SHINY_DOCS="shiny-tempo.Rmd r-helpers.R data-helpers.R ggplot-helpers.R arbetsdag.R" | ||
|
||
if [ ! -f "../tempo.html" ]; then | ||
pushd .. | ||
make | ||
popd | ||
fi | ||
|
||
for doc in ${SHINY_DOCS}; do | ||
pushd .. | ||
make shiny-server | ||
popd | ||
|
||
for doc in ${TEMPO_DOCS}; do | ||
cp ../${doc} shinyapps/. | ||
done | ||
|
||
for doc in ${SHINY_DOCS}; do | ||
mkdir -p shinyapps/shiny | ||
cp ../${doc} shinyapps/shiny/. | ||
done | ||
|
||
if [ -d ../config ]; then | ||
mkdir -p shinyapps/shiny/config | ||
cp ../config/* shinyapps/shiny/config/. | ||
fi | ||
|
||
docker run --rm -p 3838:3838 \ | ||
-v ${PWD}/shinyapps/:/srv/shiny-server/ \ | ||
-v ${HOME}/.Renviron:/home/shiny/.Renviron \ | ||
-u shiny \ | ||
docker.io/rocker/shiny-verse | ||
verifa/shiny-server | ||
|
||
popd |
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