Using docker to build a docker image containing the Ubuntu 22.04 OS (with gcloud and kubectl).
Table of Contents
- Dockerfile
- Dockerhub image
- Size: ~3.1GB
- Source Image: docker
- "ubuntu:22.04" for docker on linux
- Custom Image: docker
- ubuntu 22.04 for docker on linux
- Contains:
- gcloud SDK 419.0.0
- Installed kubectl component 1.24.10
- kubectl 1.25
- gcloud SDK 419.0.0
build-push.sh contains,
DOCKER_BUILDKIT=0 docker build -t jeffdecola/gcloud-kubectl .
docker push jeffdecola/gcloud-kubectl
Obviously, you will have to edit and create an account at dockerhub.
To run on your machine, I suggest,
docker pull jeffdecola/gcloud-kubectl
docker run --name gcloud-kubectl -dit jeffdecola/gcloud-kubectl
To bash shell into the container and check versions,
docker exec -i -t gcloud-kubectl /bin/bash
lsb_release -a
gcloud version
gcloud components list --show-versions
To see the output,
docker logs -f gcloud-kubectl