Skip to content

Commit

Permalink
Merge pull request #2 from monte-carlo-data/pchawla/kil-3051-add-life…
Browse files Browse the repository at this point in the history
…cycles-for-temp-paths

Use a shorter lifecycle for tmp objects
  • Loading branch information
pxc-dev authored Jan 18, 2024
2 parents 5db05fb + 353d4cd commit 3b35590
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,19 @@ resource "azurerm_storage_management_policy" "mcd_agent_storage_lifecycle" {
}
}
}
rule {
name = "temp-expiration"
enabled = true
filters {
blob_types = ["blockBlob", "appendBlob"]
prefix_match = ["${azurerm_storage_container.mcd_agent_storage_container.name}/${local.mcd_agent_store_data_prefix}/tmp"]
}
actions {
base_blob {
delete_after_days_since_creation_greater_than = 2
}
}
}
}

resource "azurerm_service_plan" "mcd_agent_service_plan" {
Expand Down

0 comments on commit 3b35590

Please sign in to comment.