Delete dashboards

This page describes the various ways you can delete a dashboard in Observe by Snowflake.

You can delete a dashboard in any of the following ways:

Warning

Deleting a dashboard is a permanent action. Deleted dashboards can't be recovered.

Delete a dashboard using the UI

To delete a dashboard from the Observe by Snowflake UI, click the Overflow icon () and select Delete. You can do this from the dashboard, or anywhere where this icon appears for the dashboard, such as from the Dashboard Explorer:

Delete a dashboard using Terraform

In Terraform you delete a dashboard by removing it from state and applying the change.

Suppose we have the following configuration:

terraform {
  required_providers {
    observe = {
      source = "terraform.observeinc.com/observeinc/observe"
    }
  }
}
provider "observe" {
  customer  = "123456789012"
  api_token = var.observe_api_token
  domain    = "observeinc.com"
}
resource "observe_dashboard" "my_dashboard" {
  workspace = data.observe_workspace.default.oid
  name      = "My Dashboard"
  stages    = jsonencode([])
  layout    = jsonencode({})
}

Perform the following steps to delete my_dashboard:

  1. Remove the resource "observe_dashboard" "my_dashboard" block from your .tf file.
  2. Run terraform plan to preview how observe_dashboard.my_dashboard will be destroyed.
  3. Run terraform apply to delete the dashboard.

You can also run the following command to target the dashboard without changing the configuration:

terraform destroy -target=observe_dashboard.my_dashboard

However, the dashboard is recreated the next time you run terraform apply if the dashboard is not removed from the configuration.

Lastly, you can run the following command to have Terraform forgot about the dashboard, but leave the dashboard in Observe by Snowflake:

terraform state rm observe_dashboard.my_dashboard

This command removes the resource "observe_dashboard" "my_dashboard" block from your .tf file.


Did this page help you?