This is just an extension of Docker in Docker to include the Google Cloud SDK to have an image to deploy from Gitlab CI or similar.
Just use the image in Docker Hub
on your Gitlab CI image
tags, or build one yourself (instructions below to setup in Gitlab CI).
- Create a Docker Hub account
- On the Gitlab CI setup the secret for:
DOCKER_AUTH_CONFIG
(The auth variable of Docker Hub in~/.docker/config.json
, see here)
- Build and push once locally to make the image available for Gitlab CI
- Enjoy