Install

Google Cloud Preliminaries

Follow docker install.

Follow billing setup.

Follow gcloud install.

Follow gcsfuse install.

Create a service account just for gat.

PROJECT_ID=`gcloud config get-value project`
NAME=gat-service-account
EMAIL="${NAME}@${PROJECT_ID}.iam.gserviceaccount.com"
gcloud iam service-accounts create "${NAME}"
gcloud projects add-iam-policy-binding "${PROJECT_ID}" \
                --member "serviceAccount:${EMAIL}" \
                --role "roles/owner"
mkdir -p ${XDG_CONFIG_HOME:-$HOME/.config}/gcloud
gcloud iam service-accounts keys \
       create ${XDG_CONFIG_HOME:-$HOME/.config}/gcloud/${NAME}.json \
       --iam-account "${EMAIL}"

Enable some APIs:

gcloud services enable cloudfunctions.googleapis.com
gcloud services enable containerregistry.googleapis.com
gcloud services enable pubsub.googleapis.com
gcloud services enable storage-api.googleapis.com

The gat module

git clone git@github.com:dickmao/gat.git
cd gat
make install

This modifies your $HOME/.bashrc or $HOME/.zshrc. Start a new shell for the changes to take effect.

To receive email notifications of finished jobs, you need a SendGrid account. Once you receive the SendGrid API Key, you also need to run Single Sender Verification. Then configure gat with the SendGrid profile just verified.

gat sendgrid --name [From Name] \
             --address [From Email Address] \
             --key [SendGrid API Key]