Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

Issue with Compute Url Map path matcher for bucket backend

Hi there! banging my head against a wall with what should be a simple setup. Using terraform to configure a simple path matcher in a URL map, to route a url to a specific key in the bucket.

Here's my desired config for the route rule:

route_rules {
service = google_compute_backend_bucket.app.id
match_rules {
path_template_match = "/entrypoint"
}
priority = 1
route_action {
url_rewrite {
path_template_rewrite = "/release/${var.release}/scripts/entrypoint.js"
}
}
}

Note that I validated the mapping is showing up as expected in the console. Every time I visit /entrypoint path I get a key not found response. I've tried a ton of combinations here (including wildcard matchers in the path template,  etc all to no avail. I know it can work and the rest of the config is valid because if I change the  path_template_match to a wildcard "*" it works as expected. Wondering what I'm missing here?

0 2 267