Skip to content

Commit

Permalink
add terraform 12.17
Browse files Browse the repository at this point in the history
  • Loading branch information
kahootali committed Feb 24, 2020
1 parent bf7e0d4 commit 2afc1a4
Show file tree
Hide file tree
Showing 3 changed files with 51 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ RUN apt-get update && \
apt-get install -y build-essential unzip wget git curl make jq

# Install Terraform
ARG TERRAFORM_VERSION=0.12.7
ARG TERRAFORM_VERSION=0.12.17
ARG HELM_FILENAME=terraform_${TERRAFORM_VERSION}_linux_amd64.zip
ARG TERRAFORM_URL=https://releases.hashicorp.com/terraform/${TERRAFORM_VERSION}/${HELM_FILENAME}
RUN curl -LO ${TERRAFORM_URL} \
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,6 @@ There are two folders containing different versions of terraform so two images h

1. 0.11.11
2. 0.12.7
3. 0.12.17

When you want to add a package or re-build the image, change the Dockerfile in the folder, and then copy that Dockerfile in the main Dockerfile at root directory. And change the image prefix in the Jenkinsfile.
49 changes: 49 additions & 0 deletions terraform-0.12.17/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
FROM debian:9
MAINTAINER Irtiza Ali ([email protected])

RUN apt-get update && \
apt-get install -y build-essential unzip wget git curl make jq

# Install Terraform
ARG TERRAFORM_VERSION=0.12.17
ARG HELM_FILENAME=terraform_${TERRAFORM_VERSION}_linux_amd64.zip
ARG TERRAFORM_URL=https://releases.hashicorp.com/terraform/${TERRAFORM_VERSION}/${HELM_FILENAME}
RUN curl -LO ${TERRAFORM_URL} \
&& unzip ${HELM_FILENAME} -d /tmp \
&& cp /tmp/terraform /bin/terraform \
&& rm -rf /tmp/*

# Install kubectl
ARG KUBECTL_VERSION=1.17.2
RUN curl -LO --show-error https://storage.googleapis.com/kubernetes-release/release/v${KUBECTL_VERSION}/bin/linux/amd64/kubectl && \
mv kubectl /usr/local/bin/kubectl && \
chmod +x /usr/local/bin/kubectl

# Install helm
ARG HELM_VERSION=v2.16.3
ARG HELM_FILENAME=helm-${HELM_VERSION}-linux-amd64.tar.gz
ARG HELM_URL=https://get.helm.sh/${HELM_FILENAME}
RUN curl -L ${HELM_URL} | tar zxv -C /tmp \
&& cp /tmp/linux-amd64/helm /bin/helm \
&& rm -rf /tmp/*

RUN curl -o aws-iam-authenticator https://amazon-eks.s3-us-west-2.amazonaws.com/1.14.6/2019-08-22/bin/linux/amd64/aws-iam-authenticator && \
chmod +x ./aws-iam-authenticator && \
mkdir -p $HOME/bin && cp ./aws-iam-authenticator $HOME/bin/aws-iam-authenticator && export PATH=$HOME/bin:$PATH && \
echo 'export PATH=$HOME/bin:$PATH' >> ~/.bashrc

RUN curl -o kubeseal -L https://github.com/bitnami-labs/sealed-secrets/releases/download/v0.9.6/kubeseal-linux-amd64 && \
install -m 755 kubeseal /usr/local/bin/kubeseal

RUN apt-get install -y apt-transport-https ca-certificates && \
curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - && \
echo "deb https://dl.yarnpkg.com/debian/ stable main" | tee /etc/apt/sources.list.d/yarn.list && \
curl -sL https://deb.nodesource.com/setup_10.x | bash -&& \
apt update && \
apt-get install -y yarn nodejs

RUN wget https://github.com/kward/shunit2/archive/v2.1.7.tar.gz && \
tar xvzf v2.1.7.tar.gz && mkdir -p /usr/share/shunit2/ && \
cp shunit2-2.1.7/shunit2 /usr/share/shunit2/shunit2 && \
echo 'export PATH=/usr/share/shunit2:$PATH' >> ~/.bashrc && \
curl -sL https://aka.ms/InstallAzureCLIDeb | bash

0 comments on commit 2afc1a4

Please sign in to comment.