You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

26 lines
808 B

  1. FROM docker.io/debian:buster-slim
  2. ENV DEBIAN_FRONTEND=noninteractive
  3. RUN apt-get update \
  4. && apt-get -y upgrade \
  5. && apt-get -y install --no-install-recommends \
  6. ca-certificates \
  7. curl \
  8. unzip \
  9. && apt-get clean \
  10. && rm -rf /var/lib/apt/lists/*
  11. ARG TERRAFORM_VERSION
  12. ENV TERRAFORM_VERSION="${TERRAFORM_VERSION:-0.13.5}"
  13. RUN useradd --create-home --shell /bin/bash terraform
  14. USER terraform
  15. COPY --chown=terraform:terraform . /home/terraform
  16. RUN chmod +x /home/terraform/bin/* \
  17. && echo "export PATH=/home/terraform/bin:\${PATH}" >> "/home/terraform/.bashrc" \
  18. && /home/terraform/bin/tfw -version \
  19. && rm -f /home/terraform/.terraform/*.zip
  20. VOLUME /home/terraform/source
  21. WORKDIR /home/terraform/source
  22. ENTRYPOINT ["/home/terraform/bin/tfw"]
  23. CMD ["-help"]