My attempt at matching a regex as directory name in app.yaml doesn't work :
- url: /v1_.*
static_dir: static/v1
expiration: "364d"
Although this official spec says regex syntax is supported. Is there a way to make this work ?
I.e. /v1_2014-01-29/img/logo.png
should match the static file /static/v1/img/logo.png
.
Trivia
I use Google App Engine to serve a Go webapp.
I'd like to maximize browser cache longevity, minimize number of requests and still serve the fresh versions of my css/js/png, and I believe revving filenames is a best practice to achieve this. Also as adding a variable querystring (/v1/img/logo.png?2014-01-29
) might cause proxy and cache problems, I prefer to show a variable directory name (/v1_2014-01-29/img/logo.png
), pointing to the same underlying server dir.