Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add uptime check #4

Merged
merged 10 commits into from
Nov 5, 2019
Merged

Add uptime check #4

merged 10 commits into from
Nov 5, 2019

Conversation

ajmaddaford
Copy link
Contributor

@ajmaddaford ajmaddaford commented Nov 5, 2019

Adds the uptime check that is currently manually created in production.

Configuring SSL certificate validation is not currently possible in Terraform - hashicorp/terraform-provider-google-beta#1243.

The conditions config is derived from https://cloud.google.com/monitoring/alerts/policies-in-json.

@@ -35,3 +35,7 @@ variable "project_team" {
description = "The team this project belongs to, for billing and reporting purposes, etc"
default = "eq"
}

variable "uptime_check_host" {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should add this to terraform.tfvars.example since it is mandatory.

display_name = "${var.uptime_check_host}"
timeout = "5s"
period = "60s"

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had to add project = "${var.stackdriver_workspace}" for this to work.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed. Mine worked as my project id is the same as my stackdriver workspace.

type = "uptime_url"

labels = {
project_id = "${var.stackdriver_workspace}"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This isn't needed and I think we should remove it.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, the Terraform doc isn't clear and it's in their example. Removed.

MebinAbraham
MebinAbraham previously approved these changes Nov 5, 2019
Copy link
Contributor

@JamesGardiner JamesGardiner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Needs an uptime alert policy

Copy link
Contributor

@MebinAbraham MebinAbraham left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you terraform fmt the files.

@ajmaddaford ajmaddaford merged commit a36ebd0 into master Nov 5, 2019
@ajmaddaford ajmaddaford deleted the add-uptime-check branch November 5, 2019 11:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants