Created
March 19, 2019 23:24
-
-
Save rkawajiri/c271ec1d3c83bddb9e182ed42d13d0f5 to your computer and use it in GitHub Desktop.
Google Cloud SDK without Installing Host Machine
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Aliases for Google Cloud SDK | |
# https://hub.docker.com/r/google/cloud-sdk/ | |
GCLOUD_SDK_IMAGE="google/cloud-sdk:alpine" | |
GCLOUD_CONFIG_VOLUME="gcloud-config" | |
GCLOUD_CLI_BASE="docker run --rm -it --volumes-from ${GCLOUD_CONFIG_VOLUME} -v $(pwd):/tmp/work --workdir /tmp/work ${GCLOUD_SDK_IMAGE}" | |
alias gcloud-auth-login="docker run -it --name ${GCLOUD_CONFIG_VOLUME} ${GCLOUD_SDK_IMAGE} gcloud auth login" | |
alias gcloud="${GCLOUD_CLI_BASE} gcloud" | |
alias gsutil="${GCLOUD_CLI_BASE} gsutil" | |
alias bq="${GCLOUD_CLI_BASE} bq" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment