Tags: #fastly #terraform
resource "fastly_service_v1" "test_service" {
name = "My Test Service"
domain {
name = "training.fastly.com"
}
backend {
address = "httpbin.org"
name = "test-backend"
}
vcl {
content = file("vcl/main.vcl")
main = true
name = "custom_vcl"
}
force_destroy = true
}
output "active" {
value = fastly_service_v1.test_service.active_version
}
terraform {
required_providers {
fastly = {
source = "fastly/fastly"
version = "0.27.0"
}
}
}