Skip to content

Commit

Permalink
place GH SHA env var later in Dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
Laura Bąkała authored and Laura Bąkała committed Oct 20, 2023
1 parent 009f1eb commit aea49bb
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
FROM rocker/r-ver:4.3.1

ARG github_sha
ENV GITHUB_SHA=${github_sha}
ENV RENV_CONFIG_SANDBOX_ENABLED=FALSE

WORKDIR /src/unbiased

# Install system dependencies
Expand All @@ -13,6 +9,8 @@ RUN apt update && apt-get install -y --no-install-recommends \
# sodium
libsodium-dev

ENV RENV_CONFIG_SANDBOX_ENABLED=FALSE

COPY ./renv ./renv
COPY .Rprofile .
COPY renv.lock .
Expand All @@ -23,4 +21,7 @@ COPY api/ ./api

EXPOSE 3838

ARG github_sha
ENV GITHUB_SHA=${github_sha}

CMD ["R", "-e", "plumber::plumb(dir = 'api') |> plumber::pr_run(host = '0.0.0.0', port = 3838)"]

0 comments on commit aea49bb

Please sign in to comment.