Skip to content

Commit

Permalink
Merge remote-tracking branch 'hieptq/improvement/#64-should-upgrade-t…
Browse files Browse the repository at this point in the history
…eracy-gcloud-image'
  • Loading branch information
hoatle committed Oct 16, 2019
2 parents 18ff4f0 + ef920e1 commit 94678f6
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 11 deletions.
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ env:
- IMG_REPO=mongo-connector BUILD_PATH=base IMG_TAG=latest
# - IMG_REPO=mongo-alpine BUILD_PATH=base IMG_TAG=latest
- IMG_REPO=node-ruby BUILD_PATH=base IMG_TAG=latest
- IMG_REPO=ubuntu BUILD_PATH=base IMG_TAG=16.04-dind-latest
- IMG_REPO=ubuntu BUILD_PATH=base IMG_TAG=18.04-dind-latest
- IMG_REPO=packer BUILD_PATH=latest IMG_TAG=latest
- IMG_REPO=python-coveralls BUILD_PATH=base IMG_TAG=latest
- IMG_REPO=travis BUILD_PATH=base IMG_TAG=latest
Expand Down
26 changes: 16 additions & 10 deletions google-cloud-sdk/base/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,19 @@ ENV CI_BUILD_ID=$CI_BUILD_ID CI_BUILD_REF=$CI_BUILD_REF CI_REGISTRY_IMAGE=$CI_RE
CI_BUILD_TIME=$CI_BUILD_TIME

# install google-cloud-sdk
RUN export PATH=$PATH:${HOME}/google-cloud-sdk/bin; \
export CLOUDSDK_CORE_DISABLE_PROMPTS=1; \
curl https://sdk.cloud.google.com | bash; \
gcloud components install kubectl; \
# install helm
curl https://raw.githubusercontent.com/kubernetes/helm/master/scripts/get | bash; \
# link installed bin
ln -s ${HOME}/google-cloud-sdk/bin/gcloud /usr/local/bin/gcloud; \
ln -s ${HOME}/google-cloud-sdk/bin/gsutil /usr/local/bin/gsutil; \
ln -s ${HOME}/google-cloud-sdk/bin/kubectl /usr/local/bin/kubectl;
RUN echo "deb [signed-by=/usr/share/keyrings/cloud.google.gpg] http://packages.cloud.google.com/apt cloud-sdk main" | tee -a /etc/apt/sources.list.d/google-cloud-sdk.list; \
apt-get install -qy apt-transport-https ca-certificates; \
curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | apt-key --keyring /usr/share/keyrings/cloud.google.gpg add -; \
apt-get update -qy && apt-get install -qy google-cloud-sdk; \
gcloud version;

# install kubectl
RUN apt-get update -qy && apt-get install -qy apt-transport-https; \
curl -s https://packages.cloud.google.com/apt/doc/apt-key.gpg | apt-key add -; \
echo "deb https://apt.kubernetes.io/ kubernetes-xenial main" | tee -a /etc/apt/sources.list.d/kubernetes.list; \
apt-get update -qy && apt-get install -y kubectl;

# install helm
RUN curl -LO https://git.io/get_helm.sh; \
chmod 700 get_helm.sh; \
./get_helm.sh;

0 comments on commit 94678f6

Please # to comment.