Marc Kupietz | f6bb6cb | 2023-11-18 17:17:50 +0100 | [diff] [blame] | 1 | FROM rocker/tidyverse |
| 2 | |
| 3 | RUN apt-get update -qq && apt-get -y --no-install-recommends install \ |
| 4 | libu2f-udev build-essential libglpk40 libcurl4-gnutls-dev libxml2-dev libsodium-dev libsecret-1-dev libfontconfig1-dev libssl-dev libxt6 libpq-dev |
| 5 | |
| 6 | COPY /shiny ./app |
Marc Kupietz | 6483a9b | 2023-11-21 16:31:16 +0100 | [diff] [blame] | 7 | COPY /cache ./cache |
Marc Kupietz | f6bb6cb | 2023-11-18 17:17:50 +0100 | [diff] [blame] | 8 | |
| 9 | RUN R -e "install.packages(c('devtools', 'shiny', 'shinythemes', 'highcharter'))" |
| 10 | RUN R -e 'devtools::install_git("https://korap.ids-mannheim.de/gerrit/IDS-Mannheim/idsThemeR")' |
| 11 | RUN R -e 'devtools::install_git("https://korap.ids-mannheim.de/gerrit/KorAP/RKorAPClient")' |
| 12 | RUN echo "Populating cache" |
| 13 | ENV R_CACHE_ROOTPATH=/cache |
Marc Kupietz | 6483a9b | 2023-11-21 16:31:16 +0100 | [diff] [blame] | 14 | RUN mkdir -p ${R_CACHE_ROOTPATH} |
Marc Kupietz | f6bb6cb | 2023-11-18 17:17:50 +0100 | [diff] [blame] | 15 | RUN R -e 'input=list(cq=";referTo ratskorpus-2023-1;referTo drukola.20180909.1b_words"); source("/app/app.R"); renderHighchart<-function(x) { eval(x) }; server(input,"","");' |
| 16 | |
| 17 | EXPOSE 3838 |
| 18 | CMD ["R", "-e", "shiny::runApp('/app', host = '0.0.0.0', port = 3838)"] |