1

We want to serve different applications on the same domain, based on path. For example mydomain.com Serves a WordPress website and mydomain.com/app serves a google app engine application. My natural choice was to point to mydomain.com at a cluster of NGINX machines, which are configured to proxy based on path.

My question is, is this a solid solution? I always see that NGINX regarded as a proxy for static content, where as I want to proxy any kind of content. IS there something I'm missing? What should I be looking out for when NGINX as a dynamic content proxy?

PS: Thanks to all who said that I can serve the blog from a sub-domain. I'm aware of that solution, but it's not relevant to my problem. As I have a specific requirement to serve everything from the same domain.

2 Answers 2

0

Just to add another two cents, this time from me, Nginx works really well as reverse proxy for any type of content. Standard practice is to setup application server on some random port and setup Nginx to serve content from it. Increases security and allows you to do some static file serving magic.

In your case: yes, it will work, but it will increase latency a lot if your Wordpress and Nginx cluster is "far" away from Gapp Engine servers. Reason for that is that user will contact your Nginx proxy and Nginx proxy will contact Gapp meaning that it will take suboptimal route and add processing overhead.

I would really consider what @dagnelies suggests and use subdomains instead. This way you don't really need proxy as routing will be done based on DNS results and not rules set in Nginx.

2
  • Thanks for the reply. But this is not a technical, rather an SEO constraint. So, some sort of proxying is due.
    – MeLight
    Commented Sep 26, 2016 at 13:15
  • @MeLight just remember to check how good is your connection between Nginx and GAE as this will directly impact your user experience which seems to be far more important than slightly better SEO. Google Compute Engine might be a good solution here.
    – Migol
    Commented Sep 27, 2016 at 5:58
3

Just my two cents, but can't you just:

  • point mydomain.com to your wordpress server/cluster
  • point app.mydomain.com to your GAE app

Most domain registrars enable you to do this pretty easely. Why put a proxy in between?

1
  • That's the first thing i said to my boss. But the SEO people went crazy :D So, this is strictly an SEO constraint.
    – MeLight
    Commented Sep 26, 2016 at 13:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.