Actualiser Dockerfile

This commit is contained in:
aslane 2024-03-21 15:51:38 +00:00
parent 275f4b4ef8
commit 8229e4628c
1 changed files with 56 additions and 54 deletions

View File

@ -1,54 +1,56 @@
FROM rocker/r-ver FROM rocker/r-ver
RUN apt-get update \ RUN apt-get update \
&& apt-get install -y --no-install-recommends \ && apt-get install -y --no-install-recommends \
pandoc \ pandoc \
pandoc-citeproc \ pandoc-citeproc \
libcurl4-gnutls-dev \ libcurl4-gnutls-dev \
libcairo2-dev \ libcairo2-dev \
libxt-dev \ libxt-dev \
xtail \ xtail \
libssl-dev \ libssl-dev \
libicu-dev \ libicu-dev \
wget wget
# Create a directory for your Shiny app # Create a directory for your Shiny app
RUN mkdir -p /srv/shiny RUN mkdir -p /srv/shiny
RUN apt-get update RUN apt-get update
RUN apt-get install -y cmake RUN apt-get install -y cmake
RUN apt-get install -y libssl-dev RUN apt-get install -y libssl-dev
RUN apt-get install -y libharfbuzz-dev RUN apt-get install -y libharfbuzz-dev
RUN apt-get install -y libfribidi-dev RUN apt-get install -y libfribidi-dev
RUN apt-get install -y libxml2-dev RUN apt-get install -y libxml2-dev
RUN apt-get install -y libexpat1 RUN apt-get install -y libexpat1
RUN apt-get install -y libfontconfig1-dev RUN apt-get install -y libfontconfig1-dev
# Copy the Shiny app to the container # Copy the Shiny app to the container
COPY app.R /srv/shiny/app.R COPY app.R /srv/shiny/app.R
COPY README.md /srv/shiny/README.md COPY README.md /srv/shiny/README.md
COPY arbre1.png /srv/shiny/arbre1.png COPY arbre1.png /srv/shiny/arbre1.png
COPY arbre2.png /srv/shiny/arbre2.png COPY arbre2.png /srv/shiny/arbre2.png
COPY .Renviron /srv/shiny/.Renviron COPY .Renviron /srv/shiny/.Renviron
# Expose the port Shiny app runs on # Expose the port Shiny app runs on
EXPOSE 8080 EXPOSE 8080
# Command to run the Shiny app # Command to run the Shiny app
RUN R -e "install.packages('nloptr',dependencies=TRUE,repos='http://cran.rstudio.com')" RUN R -e "install.packages('nloptr',dependencies=TRUE,repos='http://cran.rstudio.com')"
RUN R -e "install.packages('emmeans',dependencies=TRUE,repos='http://cran.rstudio.com')" RUN R -e "install.packages('emmeans',dependencies=TRUE,repos='http://cran.rstudio.com')"
RUN R -e "install.packages('officer',dependencies=TRUE,repos='http://cran.rstudio.com')" RUN R -e "install.packages('officer',dependencies=TRUE,repos='http://cran.rstudio.com')"
RUN R -e "install.packages(c('dplyr', 'shiny', 'readxl', 'remotes', 'httpuv', 'shinythemes', 'DT', 'ggplot2', 'gridExtra', 'emmeans'), repos = 'http://cran.rstudio.com/', method='wget',dependencies=TRUE)" RUN R -e "install.packages(c('dplyr', 'shiny', 'readxl', 'remotes', 'httpuv', 'shinythemes', 'DT', 'ggplot2', 'gridExtra', 'emmeans'), repos = 'http://cran.rstudio.com/', method='wget',dependencies=TRUE)"
RUN R -e "install.packages(c('officer','car', 'markdown', 'plotly', 'factoextra', 'shinylogs', 'auth0', 'httr', 'shinyjs','urltools','openssl'), repos = 'http://cran.rstudio.com/', method='wget',dependencies=TRUE)" RUN R -e "install.packages(c('officer','car', 'markdown', 'plotly', 'factoextra', 'shinylogs', 'auth0', 'httr', 'shinyjs','urltools','openssl'), repos = 'http://cran.rstudio.com/', method='wget',dependencies=TRUE)"
CMD ["R", "-e", "shiny::runApp('/srv/shiny', host='0.0.0.0', port=8080, launch.browser = FALSE)"] RUN R -e "install.packages('pls',dependencies=TRUE,repos='http://cran.rstudio.com')"
RUN R -e "install.packages('shinyBS',dependencies=TRUE,repos='http://cran.rstudio.com')"
CMD ["R", "-e", "shiny::runApp('/srv/shiny', host='0.0.0.0', port=8080, launch.browser = FALSE)"]