2. QUICKSTART¶
Do these steps to get your local machine ready.
2.1. Prepare your local environment.¶
- Add your public key half to /gcp/config/authorized_keys file
- For example:
cat ~/.ssh/.id_rsa.pub >> {PATH_TO_REPO_CLONE}/gcp/config/authorized_keys
- Create a file called /aws/terraform.tfvars
- For example:
project_id = "" # Put your GCP Project ID.
bucket_name = "my-bucket-48693" # Put the desired GCS Bucket name.
- Run the “config” script in this repo.
- Correct the errors until you get output as below.
2.2. Log in via gcloud¶
- Be sure to use your gmail or personal account
- Do not use your palo alto email to sign in.
gcloud auth login
gcloud projects list
gcloud projects create secops-iac-ctf-000378
gcloud config set project secops-iac-ctf-000378
- Use the cloud console to create a service account
- Save the file and then do like so:
export GOOGLE_APPLICATION_CREDENTIALS="/Users/fdiaz/.config/gcloud/secops-iac-ctf-000378-ca7e78916a38.json"
2.3. Terraform Time¶
cd gcp/deployment
terraform init
terraform plan -out franklin.out
terraform apply "franklin.out"