fix passing build args to drone
All checks were successful
continuous-integration/drone/push Build is passing
continuous-integration/drone/tag Build is passing

This commit is contained in:
Robert Kaussow 2020-02-20 21:19:20 +01:00
parent aa77b4d263
commit c4f40ca5c1

View File

@ -8,7 +8,6 @@ LABEL maintainer="Robert Kaussow <mail@geeklabor.de>" \
ARG ANSIBLE_VERSION=2.9.0 ARG ANSIBLE_VERSION=2.9.0
ARG MOLECULE_VERSION=latest ARG MOLECULE_VERSION=latest
ARG TEST="${MOLECULE_VERSION}"
ENV PY_COLORS=1 \ ENV PY_COLORS=1 \
USER=root \ USER=root \
@ -16,29 +15,26 @@ ENV PY_COLORS=1 \
COPY overlay/ / COPY overlay/ /
RUN \ RUN apk add --update --no-cache --virtual .build-deps gcc make libffi-dev musl-dev \
# apk add --update --no-cache --virtual .build-deps gcc make libffi-dev musl-dev \ openssl-dev python3-dev && \
# openssl-dev python3-dev && \ apk add --update --no-cache git openssh-client && \
# apk add --update --no-cache git openssh-client && \
# Required to fix hcloud dependency: # Required to fix hcloud dependency:
# hcloud 1.6.3 has requirement requests<2.23,>=2.20, but you'll have requests 2.23.0 # hcloud 1.6.3 has requirement requests<2.23,>=2.20, but you'll have requests 2.23.0
# echo "Installing ansible 'v$ANSIBLE_VERSION' ..." && \ echo "Installing ansible 'v$ANSIBLE_VERSION' ..." && \
# pip install -qq --upgrade --no-cache-dir pip setuptools requests~=2.22.0 && \ pip install -qq --upgrade --no-cache-dir pip setuptools requests~=2.22.0 && \
# pip install -qq --no-cache-dir ansible~="$ANSIBLE_VERSION" && \ pip install -qq --no-cache-dir ansible~="$ANSIBLE_VERSION" && \
# echo "Installing requirements ..." && \ echo "Installing requirements ..." && \
echo "$TEST" && \ MOLECULE_VERSION="${MOLECULE_VERSION#v}" && \
# MOLECULE_VERSION="${MOLECULE_VERSION#v}" && \ MOLECULE_MAJOR="${MOLECULE_VERSION%%.*}" && \
# MOLECULE_MAJOR="${MOLECULE_VERSION%%.*}" && \ pip install -qq --no-cache-dir -r /root/requirements.txt && \
echo "$MOLECULE_VERSION" && \ if [ -z "${MOLECULE_MAJOR//[0-9]}" ] && [ -n "$MOLECULE_MAJOR" ]; then \
# pip install -qq --no-cache-dir -r /root/requirements.txt && \ echo "Installing molecule 'v$MOLECULE_VERSION' ..." && \
# if [ -z "${MOLECULE_MAJOR//[0-9]}" ] && [ -n "$MOLECULE_MAJOR" ]; then \ pip install -qq --no-cache-dir molecule~="$MOLECULE_VERSION"; \
# echo "Installing molecule 'v$MOLECULE_VERSION' ..." && \ else \
# pip install -qq --no-cache-dir molecule~="$MOLECULE_VERSION"; \ echo "Installing latest molecule ..." && \
# else \ pip install -qq --no-cache-dir molecule; \
# echo "Installing latest molecule ..." && \ fi && \
# pip install -qq --no-cache-dir molecule; \ apk del .build-deps && \
# fi && \
# apk del .build-deps && \
rm -rf /var/cache/apk/* && \ rm -rf /var/cache/apk/* && \
rm -rf /tmp/* && \ rm -rf /tmp/* && \
rm -rf /root/.cache/ rm -rf /root/.cache/