ansible-lint/Dockerfile
Aaron Riedel 1bddf19134
All checks were successful
continuous-integration/drone/push Build is passing
add option to choose profile
2023-02-15 01:20:42 +01:00

18 lines
No EOL
511 B
Docker

FROM amd64/python:3.11.2-alpine3.16
RUN apk add --no-cache git
WORKDIR ./
ARG PUID=1000
ENV GROUP dockergroup
ENV USER docker
ENV HOMEDIR "/home/${USER}"
ENV PATH ${HOMEDIR}/.local/bin:$PATH
ENV PROFILE production
RUN addgroup -S "${GROUP}" && adduser -S "${USER}" -G "${GROUP}"
USER ${USER}
WORKDIR ${HOMEDIR}
COPY requirements.txt .
RUN pip install --no-cache-dir -r requirements.txt
RUN rm requirements.txt
RUN git config --global --add safe.directory /drone/src
CMD [ "ansible-lint", "--profile $PROFILE" ]