Skip to content

Commit

Permalink
install using pipx
Browse files Browse the repository at this point in the history
Signed-off-by: Thomas Sjögren <[email protected]>
  • Loading branch information
konstruktoid committed Dec 13, 2023
1 parent fe057fe commit 3147c9b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
11 changes: 5 additions & 6 deletions action-lint/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,14 @@ LABEL "homepage"="https://github.com/konstruktoid/ansible-role-dns"
LABEL "maintainer"="Thomas Sjögren <[email protected]>"

ENV CRYPTOGRAPHY_DONT_BUILD_RUST 1
ENV PATH="${PATH}:/root/.local/bin"

RUN apk --update --no-cache add cargo gcc git g++ libffi-dev openssl-dev \
musl-dev python3-dev && \
musl-dev python3-dev py3-pip && \
if [ ! -e /usr/bin/python ]; then ln -sf python3 /usr/bin/python ; fi && \
python3 -m ensurepip --upgrade && \
python3 -m pip install --no-cache-dir --upgrade pip && \
python3 -m pip install --no-cache-dir wheel && \
python3 -m pip install --no-cache-dir cryptography passlib && \
python3 -m pip install --no-cache-dir git+https://github.com/ansible/ansible-lint.git && \
python3 -m pip install --break-system-packages --no-cache-dir --upgrade pipx && \
python3 -m pipx install git+https://github.com/ansible/ansible-lint.git && \
apk del gcc musl-dev python3-dev && \
rm -rf /var/cache/*

COPY entrypoint.sh /entrypoint.sh
Expand Down
2 changes: 2 additions & 0 deletions action-lint/entrypoint.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#!/bin/sh -l

export PATH="${PATH}:/root/.local/bin"

echo "# Running ansible-lint"
ansible-lint --version

Expand Down

0 comments on commit 3147c9b

Please sign in to comment.