[1.2.5] Use Google CDN for a GAE hosted app

50 views
Skip to first unread message

AleX

unread,
Oct 17, 2012, 11:42:33 AM10/17/12
to play-fr...@googlegroups.com
Hello,

I host my app on Google App Engine using "play-gae" and siena module. So far everything works well :)

We would like to use the Google CDN provided for GAE apps (https://developers.google.com/appengine/docs/java/gettingstarted/staticfiles) but all our static files are in "public" play folder. Is there anyone who knows how can i tell to GAE to "CDN'd" these static files ?


Tom Carchrae

unread,
Oct 17, 2012, 11:54:24 AM10/17/12
to play-fr...@googlegroups.com
Not clear which CDN you are referring to.  The link you provided is for including in a WAR - as Play has already done for you in the public dir.

Now if you want them to be hosted on a read CDN (not GAE), then you can copy out the files and change all references to point to the CDN.  Perhaps someone may have written a module for it but it is simple: just change the URL that references each file in /public and point it to your CDN URL.

Tom




--
You received this message because you are subscribed to the Google Groups "play-framework" group.
To post to this group, send email to play-fr...@googlegroups.com.
To unsubscribe from this group, send email to play-framewor...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/play-framework?hl=en.

Tom Carchrae

unread,
Oct 17, 2012, 11:54:46 AM10/17/12
to play-fr...@googlegroups.com
sorry, read -> real CDN (not GAE)

Tom Carchrae

unread,
Oct 17, 2012, 11:58:12 AM10/17/12
to play-fr...@googlegroups.com
I beg your pardon, I should have read your link more closely.

You probably want to specify the <static files> part of appengine-web.xml and basically include the /public dir that way

AleX

unread,
Oct 17, 2012, 12:02:35 PM10/17/12
to play-fr...@googlegroups.com
Thank you Tom for your answer, i'll try it soon :)
Do you know if there is a way to determine if my static ressources are served by my play app or by the static-ressources-dedicated-servers ?

Tom Carchrae

unread,
Oct 17, 2012, 1:08:22 PM10/17/12
to play-fr...@googlegroups.com
It has been over six months since I used GAE, but you may be able to tell from the log.  

Perhaps one way to tell would be to get a file that does not exist and see if it generates a Play 404 vs the GAE static 404.
Reply all
Reply to author
Forward
0 new messages