This repository contains terraform scripts for provisioning Census EQ Stackdriver Monitoring and Alert Policies to Google Cloud Platform.
Provision an environment following the instructions found in the census-eq-terraform README.
Set up a Stackdriver Workspace:
- Visit the Stackdriver Console.
- When prompted, choose Create a new workspace and click Continue.
- When prompted to Select or Create a Google Cloud Platform project, if it is not already selected, select your project.
- Click the Continue button.
- You can skip the Monitor AWS accounts by clicking Skip AWS Setup button.
- The next page shows how to Install the Stackdriver Agents but this can be skipped as it is already available on the Kubernetes Engine.
- Click the Continue button.
- On the Get Reports by Email page you can simply select any of the options depending on whether you want to receive the reports.
- Click the Continue button.
- The actual creation of the account and underlying resources takes a few minutes. Once completed you can press the Launch monitoring button.
Logging metric based monitoring and alert policies must first be provisioned to your environment using the terraform scripts in https://github.com/ONSdigital/census-eq-terraform.
Rename terraform.tfvars.example
to terraform.tfvars
and fill in the values. (Ask a team member for help).
Create with EXISTING_PROJECT_ID=your-project-id ./create.sh
.
Destroy with EXISTING_PROJECT_ID=your-project-id ./destroy.sh
Terraform state will by default be stored in the census-eq-monitoring-tfstate
bucket, this bucket can be overridden by setting the TERRAFORM_STATE_BUCKET
environment variable.