-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
55 lines (42 loc) · 1.89 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
FROM google/cloud-sdk:alpine
LABEL vendor="0+X"
LABEL maintainer="Sebastian Mandrean <sebastian@0x.se>"
ARG KUBE_VERSION=1.16.13
ARG KUBE_SRC=https://storage.googleapis.com/kubernetes-release/release/v$KUBE_VERSION/bin/linux/amd64/kubectl
ARG KUBE_DEST=/usr/local/bin/kubectl
ARG HELM_VERSION=3.3.4
ARG HELM_SRC=https://get.helm.sh/helm-v$HELM_VERSION-linux-amd64.tar.gz
ARG HELM_DEST=/usr/local/bin/helm
ARG SKAFFOLD_VERSION=1.15.0
ARG SKAFFOLD_SRC=https://storage.googleapis.com/skaffold/releases/v$SKAFFOLD_VERSION/skaffold-linux-amd64
ARG SKAFFOLD_DEST=/usr/local/bin/skaffold
ARG GIT_CRYPT_VERSION=0.6.0-r1
ARG GIT_CRYPT_SRC=https://github.com/sgerrand/alpine-pkg-git-crypt/releases/download/$GIT_CRYPT_VERSION/git-crypt-$GIT_CRYPT_VERSION.apk
ARG GIT_CRYPT_PUB_KEY_SRC=https://raw.githubusercontent.com/sgerrand/alpine-pkg-git-crypt/master/sgerrand.rsa.pub
ARG GIT_CRYPT_PUB_KEY_DEST=/etc/apk/keys/sgerrand.rsa.pub
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
# Install *nix dependencies
RUN apk --no-cache add git curl jq docker ca-certificates && \
apk --no-cache del wget
# Update & install gcloud dependencies
RUN gcloud components update --quiet && \
gcloud auth configure-docker && \
# Kubectl
curl -#SLo $KUBE_DEST $KUBE_SRC && \
chmod +x $KUBE_DEST && \
# Helm
curl -#SL $HELM_SRC | tar zxvf - && \
mv linux-amd64/helm $HELM_DEST && rm -rf linux-amd64 && \
chmod +x $HELM_DEST && \
mkdir -p ~/.kube && \
# Skaffold
curl -#SLo $SKAFFOLD_DEST $SKAFFOLD_SRC && \
chmod +x $SKAFFOLD_DEST
# Add Helm repos
RUN helm repo add zeroplusx http://charts.0x.se && \
helm repo add incubator https://kubernetes-charts-incubator.storage.googleapis.com/ && \
helm repo update
# Install git-crypt
RUN curl -#SLo $GIT_CRYPT_PUB_KEY_DEST $GIT_CRYPT_PUB_KEY_SRC && \
curl -#SLO $GIT_CRYPT_SRC && \
apk --no-cache add libressl git-crypt-$GIT_CRYPT_VERSION.apk