-
Notifications
You must be signed in to change notification settings - Fork 757
Description
Confirmation
- This is a bug with an existing resource and is not a feature request or enhancement. Feature requests should be submitted with Cloudflare Support or your account team.
- I have searched the issue tracker and my issue isn't already found.
- I have replicated my issue using the latest version of the provider and it is still present.
Terraform and Cloudflare provider version
Terraform v1.13.4
on darwin_arm64
+ provider registry.terraform.io/cloudflare/cloudflare v5.12.0
Affected resource(s)
cloudflare_worker_version
Terraform configuration files
resource "cloudflare_worker" "worker" {
account_id = var.account_id
name = "worker"
}
resource "cloudflare_worker_version" "worker_version" {
account_id = var.account_id
compatibility_date = "2025-11-01"
compatibility_flags = ["nodejs_compat"]
limits = { cpu_ms = 3000 }
main_module = "main.js"
modules = [
{
name = "main.js"
content_file = "${path.module}/main.js"
content_type = "application/javascript+module"
}
]
worker_id = cloudflare_worker.worker.id
}
resource "cloudflare_workers_deployment" "worker_deployment" {
account_id = var.account_id
script_name = cloudflare_worker.worker.name
strategy = "percentage"
versions = [{
percentage = 100
version_id = cloudflare_worker_version.worker_version.id
}]
}Link to debug output
https://gist.github.com/kamronbekshodmonov/ddd0f2c97750cf2ada69caf5d8855d1c
Panic output
No response
Expected output
After running terraform apply, the worker should be deployed with the updated limits.cpu_ms = 3000 value
Actual output
Terraform reports a successful apply with no errors. However, when viewing the worker in the Cloudflare dashboard, the CPU time limit field still shows the default 50ms instead of the 3000ms value defined in Terraform. The new value is only visible if we click the edit icon
At the moment, the only way to make the updated limit take effect is to manually open the worker in the dashboard, update the value, and click deploy. Until that manual redeploy is done, the worker continues running with the old 50ms limit, even though Terraform shows everything as successfully applied
Steps to reproduce
- Create main.tf
- Add variables
- Run
terraform apply
Additional factoids
No response
References
No response