mirror of
https://github.com/super-linter/super-linter.git
synced 2024-11-25 02:01:02 -05:00
build: install lintr in a dedicated stage (#5247)
This commit is contained in:
parent
a26db6d34d
commit
1f2fbb14cd
1 changed files with 16 additions and 6 deletions
22
Dockerfile
22
Dockerfile
|
@ -95,6 +95,17 @@ COPY TEMPLATES/.tflint.hcl /action/lib/.automation/
|
||||||
# Initialize TFLint plugins so we get plugin versions listed when we ask for TFLint version
|
# Initialize TFLint plugins so we get plugin versions listed when we ask for TFLint version
|
||||||
RUN tflint --init -c /action/lib/.automation/.tflint.hcl
|
RUN tflint --init -c /action/lib/.automation/.tflint.hcl
|
||||||
|
|
||||||
|
FROM python:3.12.1-alpine3.19 as lintr-installer
|
||||||
|
|
||||||
|
RUN apk add --no-cache \
|
||||||
|
bash \
|
||||||
|
R
|
||||||
|
|
||||||
|
SHELL ["/bin/bash", "-o", "errexit", "-o", "nounset", "-o", "pipefail", "-c"]
|
||||||
|
|
||||||
|
COPY scripts/install-lintr.sh scripts/install-r-package-or-fail.R /
|
||||||
|
RUN /install-lintr.sh && rm -rf /install-lintr.sh /install-r-package-or-fail.R
|
||||||
|
|
||||||
FROM python:3.12.1-alpine3.19 as base_image
|
FROM python:3.12.1-alpine3.19 as base_image
|
||||||
|
|
||||||
LABEL com.github.actions.name="Super-Linter" \
|
LABEL com.github.actions.name="Super-Linter" \
|
||||||
|
@ -204,12 +215,6 @@ RUN --mount=type=secret,id=GITHUB_TOKEN /install-chktex.sh && rm -rf /install-ch
|
||||||
# Set work directory back to root because some scripts depend on it
|
# Set work directory back to root because some scripts depend on it
|
||||||
WORKDIR /
|
WORKDIR /
|
||||||
|
|
||||||
#################
|
|
||||||
# Install Lintr #
|
|
||||||
#################
|
|
||||||
COPY scripts/install-lintr.sh scripts/install-r-package-or-fail.R /
|
|
||||||
RUN /install-lintr.sh && rm -rf /install-lintr.sh /install-r-package-or-fail.R
|
|
||||||
|
|
||||||
#################################
|
#################################
|
||||||
# Install luacheck and luarocks #
|
# Install luacheck and luarocks #
|
||||||
#################################
|
#################################
|
||||||
|
@ -351,6 +356,11 @@ COPY --from=clang-format /usr/bin/clang-format /usr/bin/
|
||||||
########################
|
########################
|
||||||
COPY --from=python-builder /venvs /venvs
|
COPY --from=python-builder /venvs /venvs
|
||||||
|
|
||||||
|
#################
|
||||||
|
# Install Lintr #
|
||||||
|
#################
|
||||||
|
COPY --from=lintr-installer /usr/lib/R /usr/lib/R
|
||||||
|
|
||||||
#####################
|
#####################
|
||||||
# Install Bash-Exec #
|
# Install Bash-Exec #
|
||||||
#####################
|
#####################
|
||||||
|
|
Loading…
Reference in a new issue