Files
bank-fraud-baf-lakehouse/Dockerfile
Rob Wiederstein fdd75f80da
All checks were successful
Deploy Lakehouse Docs / build-and-deploy (push) Successful in 15m5s
Lint & Format Check / Link Check (push) Successful in 4s
Lint & Format Check / Format Check (styler) (push) Successful in 18s
R Package Tests / test (push) Successful in 55s
Align Dockerfile base image to rocker/verse:4.4 to match CI workflow
2026-02-23 06:23:41 -05:00

46 lines
1.2 KiB
Docker

FROM rocker/verse:4.4
# System dependencies for arrow, lightgbm, and ggplot2 (ragg/textshaping)
# Quarto is pre-installed in rocker/verse
RUN apt-get update && apt-get install -y --no-install-recommends \
cmake \
libcurl4-openssl-dev \
libssl-dev \
libxml2-dev \
libglpk-dev \
libfontconfig1-dev \
libfreetype6-dev \
libharfbuzz-dev \
libfribidi-dev \
libpng-dev \
libjpeg-dev \
libtiff-dev \
libzstd-dev \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /app
# Copy renv infrastructure first so package restore is a cached layer.
# Changes to source code below will not invalidate this layer.
COPY renv.lock .Rprofile ./
COPY renv/activate.R renv/settings.json renv/
RUN Rscript -e "renv::restore()"
# Copy the full package source
COPY . .
# Install the local package into the renv library
RUN Rscript -e "renv::install('.')"
# Non-secret default — override with --env at runtime if needed
ENV BAF_BUCKET=lake
# Secrets and endpoint are injected at runtime — never baked into the image:
# docker run \
# --env BAF_ENDPOINT=172.19.0.1:9100 \
# --env BAF_KEY=... \
# --env BAF_SECRET=... \
# baflakehouse
CMD ["Rscript", "deploy.R"]