This file contains 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
#!/usr/bin/env bash | |
# Docs: https://cloud.google.com/anthos/gke/docs/aws/how-to/prerequisites | |
# NOTE: MUST have `jq` installed for JSON parsing to set ENV vars | |
export PROJECT_ID=$(gcloud config get-value project) | |
export PROJECT_OWNER=$(gcloud config get-value core/account) # set orig val | |
# confirm aws CLI working | |
aws --version |
This file contains 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
terraform { | |
required_providers { | |
google = { | |
source = "hashicorp/google" | |
version = ">= 3.37" | |
} | |
google-beta = { | |
source = "hashicorp/google-beta" | |
version = ">= 3.37" | |
} |
This file contains 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
#!/usr/bin/env bash | |
# Docs: https://cloud.google.com/anthos/gke/docs/aws/how-to/prerequisites | |
# NOTE: MUST have `jq` installed for JSON parsing to set ENV vars | |
export PROJECT_ID=$(gcloud config get-value project) | |
export PROJECT_USER=$(gcloud config get-value core/account) # set current user | |
# confirm aws CLI working | |
aws --version |
This file contains 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
#!/usr/bin/env bash | |
# https://cloud.google.com/anthos/gke/docs/aws/how-to/installing-management | |
# NOTE: MUST have `jq` installed for JSON parsing to set ENV vars | |
export PROJECT_ID=$(gcloud config get-value project) | |
export PROJECT_OWNER=$(gcloud config get-value core/account) # set orig val | |
export ANTHOS_GKE_VERSION=$(anthos-gke version) | |
export AWS_REGION="us-east-2" | |
export ADMIN_AWS_IAM_ARN=$(aws sts get-caller-identity | jq '.Arn') |
This file contains 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
#!/usr/bin/env bash | |
# https://cloud.google.com/anthos/gke/docs/aws/how-to/creating-user-cluster | |
# from setup-02-mgmt.sh | |
unset HTTP_PROXY # reset | |
export NODE_KEY_PATH=$(PWD)/node-key.json | |
export GOOGLE_APPLICATION_CREDENTIALS=$NODE_KEY_PATH | |
# create example user cluster config |
This file contains 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
#!/usr/bin/env bash | |
# https://cloud.google.com/anthos/gke/docs/aws/how-to/connecting-to-a-cluster | |
# from setup-02-mgmt.sh | |
unset HTTP_PROXY # reset | |
export NODE_KEY_PATH=$(PWD)/node-key.json | |
export GOOGLE_APPLICATION_CREDENTIALS=$NODE_KEY_PATH | |
# make sure bastion_tunnel.sh is running |
This file contains 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
#!/usr/bin/env bash | |
export PROJECT_ID=$(gcloud config get-value project) | |
export PROJECT_USER=$(gcloud config get-value core/account) # set current user | |
export CLUSTER_NAME="central" | |
export CLUSTER_LOCATION="us-central1" | |
export MACHINE_TYPE="n1-standard-4" | |
export NODE_POOL_NAME="default-pool" | |
export NETWORK_NAME="anthos-demo" |
This file contains 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
#!/usr/bin/env bash | |
export ORG_ID="CHANGEME" | |
export PROJECT_ID=$(gcloud config get-value project) | |
export PROJECT_USER=$(gcloud config get-value core/account) # set current user | |
export PROJECT_NUMBER=$(gcloud projects describe $PROJECT_ID --format="value(projectNumber)") | |
export IDNS=${PROJECT_ID}.svc.id.goog # workflow identity domain | |
export DATA_SA_NAME="data-viewer" | |
export DATA_SA_ID="${DATA_SA_NAME}@${PROJECT_ID}.iam.gserviceaccount.com" |
This file contains 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
#!/usr/bin/env bash | |
export ORG_ID="CHANGEME" | |
export PROJECT_ID=$(gcloud config get-value project) | |
export PROJECT_USER=$(gcloud config get-value core/account) # set current user | |
export PROJECT_NUMBER=$(gcloud projects describe $PROJECT_ID --format="value(projectNumber)") | |
export IDNS=${PROJECT_ID}.svc.id.goog # workflow identity domain | |
export DATA_SA_NAME="data-viewer" | |
export DATA_SA_ID="${DATA_SA_NAME}@${PROJECT_ID}.iam.gserviceaccount.com" |
This file contains 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
#!/usr/bin/env bash | |
# https://cloud.google.com/appengine/docs/standard/python3/quickstart | |
export PROJECT_ID="mike-gae-custom-tls" | |
export PROJECT_USER=$(gcloud config get-value core/account) # set current user | |
export PROJECT_NUMBER=$(gcloud projects describe $PROJECT_ID --format="value(projectNumber)") | |
export GAE_SA="${PROJECT_NUMBER}@cloudbuild.gserviceaccount.com" | |
export POLICY_NAME="pci-policy" |