File size: 1,071 Bytes
268801b
3e388f2
268801b
 
 
1a187cb
268801b
1a187cb
268801b
4bccde6
268801b
 
1a187cb
 
4bccde6
1a187cb
4bccde6
3e388f2
268801b
1a187cb
 
4bccde6
1a187cb
268801b
1a187cb
3e388f2
1a187cb
 
3e388f2
1a187cb
3e388f2
1a187cb
 
 
 
4bccde6
268801b
1a187cb
268801b
1a187cb
3e388f2
268801b
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
FROM rocker/shiny:latest

WORKDIR /code

# Minimal system deps for headless Chromium (webshot2) + TLS
RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends \
    chromium \
    libnss3 \
    libgbm1 \
    libx11-6 \
    libxrender1 \
    libxext6 \
    libgtk-3-0 \
    fonts-liberation \
    fonts-dejavu \
    ca-certificates \
 && rm -rf /var/lib/apt/lists/*

# Let webshot2/chromote find Chromium and use safe flags in containers
ENV CHROME_BIN=/usr/bin/chromium
ENV CHROMOTE_CHROME=/usr/bin/chromium
ENV CHROMOTE_CHROME_ARGS="--no-sandbox --disable-dev-shm-usage"

# R packages used by this app
RUN install2.r --error --skipinstalled \
    shiny \
    shinydashboard \
    DT \
    dplyr \
    shinyjs \
    readr \
    webshot2 \
    htmlwidgets \
    ggplot2

# App code
COPY . /code

# Serve on 7860 to match your runApp call
EXPOSE 7860

# Run app (respects $PORT if set by the platform)
CMD ["R", "--quiet", "-e", "options(shiny.port=as.integer(Sys.getenv('PORT', 7860)), shiny.host='0.0.0.0'); shiny::runApp('/code')"]