2022-03-18 20:03:45 +00:00
|
|
|
FROM golang:alpine
|
|
|
|
|
|
|
|
ARG TERRAFORM_VERSION=0.12.10
|
|
|
|
ENV TERRAFORM_VERSION=$TERRAFORM_VERSION
|
|
|
|
|
|
|
|
|
|
|
|
RUN apk update && \
|
|
|
|
apk upgrade --update-cache --available && \
|
|
|
|
apk add curl git jq bash openssh unzip gcc g++ make ca-certificates && \
|
2022-04-13 15:55:05 +00:00
|
|
|
curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl" && \
|
2022-03-18 20:03:45 +00:00
|
|
|
chmod +x ./kubectl && \
|
2022-04-13 15:55:05 +00:00
|
|
|
mv ./kubectl /usr/local/bin && \
|
|
|
|
mkdir tmp && \
|
2022-03-18 20:03:45 +00:00
|
|
|
curl "https://releases.hashicorp.com/terraform/${TERRAFORM_VERSION}/terraform_${TERRAFORM_VERSION}_linux_amd64.zip" -o tmp/terraform.zip && \
|
|
|
|
unzip tmp/terraform.zip -d /usr/local/bin && \
|
|
|
|
chmod +x /usr/local/bin/terraform && \
|
|
|
|
rm -rf tmp
|
|
|
|
|
|
|
|
WORKDIR $GOPATH/src/github.com/k3s-io/k3s
|
|
|
|
|
|
|
|
COPY . .
|
2022-04-05 20:13:48 +00:00
|
|
|
RUN go install github.com/gruntwork-io/terratest/modules/terraform
|
|
|
|
RUN go install -u github.com/onsi/gomega
|
|
|
|
RUN go install -u github.com/onsi/ginkgo/v2
|
|
|
|
RUN go install -u golang.org/x/crypto/...
|