-
Notifications
You must be signed in to change notification settings - Fork 4.5k
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
timeframe attribute from azurerm_subscription_cost_management_view does not work properly #22933
Comments
Thanks for raising this issue. Seems "granularity" needs to be set to "Daily". |
I do encounter the same issue while trying to replicate the view below. Additionally, it seems like we cannot set the report type as
|
I have tried to set the granularity to Daily but the problem persists. |
I manage to get the view I wanted by using the AzAPI resource as workaround
|
Hello @cerocool1203,
but it throws this error:│ RESPONSE 404: 404 Not Found
|
Is there any solution on the issue? |
Is there an existing issue for this?
Community Note
I have the following code to create a subscription cost management view:
`resource "azurerm_subscription_cost_management_view" "subscription_cost_management_view" {
name = "costview-${var.subscription_name}"
display_name = "costview-${var.subscription_name}"
chart_type = "StackedColumn"
accumulated = false
subscription_id = "/subscriptions/${var.subscription_id}"
report_type = "Usage"
timeframe = "YearToDate"
dataset {
granularity = "Monthly"
}
pivot {
name = "ResourceId"
type = "Dimension"
}
pivot {
name = "ResourceGroupName"
type = "Dimension"
}
pivot {
name = "ServiceName"
type = "Dimension"
}
}`
But when I go to this view, the timeframe is not YearToDate:
Terraform Version
1.5.5
AzureRM Provider Version
3.69.0
Affected Resource(s)/Data Source(s)
azurerm_subscription_cost_management_view
Terraform Configuration Files
Debug Output/Panic Output
Expected Behaviour
To see the costview with YearToDate timeframe
Actual Behaviour
The costview is just for the actual month
Steps to Reproduce
terraform apply
Important Factoids
No response
References
No response
The text was updated successfully, but these errors were encountered: