multiple application on same subdomain.

497 views
Skip to first unread message

nav...@senspan.com

unread,
Jun 17, 2015, 4:27:06 PM6/17/15
to google-a...@googlegroups.com
hii, 

can we have multiple application on a single subdomain ?

because i have ssl certificate for only 1 sub domain , 
and  don't want to buy other one ,
 so i want to deploy the 2nd application under same subdomain name.

eg  sub.hellow.com  can have 2 application in it ?

nav...@senspan.com

unread,
Jun 17, 2015, 4:43:37 PM6/17/15
to google-a...@googlegroups.com

and I dun't want all under same project .

can we deploy both project separately then assign then same subdomain name.?
  

 

Nick (Cloud Platform Support)

unread,
Jun 17, 2015, 7:38:09 PM6/17/15
to google-a...@googlegroups.com, nav...@senspan.com
Hi Navneet, 

I'll try to answer your questions simply:

can we have multiple application on a single subdomain ?

It depends what you mean. A single fully-qualified domain name (like www.google.com) maps to a single IP address in the DNS system. Ultimately, the unique computer identified by that IP address will receive a TCP connection on port 80 from your user's computer. What gets sent in the response to GET / HTTP/1.1 will be one html document, representing the single website that they see.

You can, however, as an example, use headers to dispatch requests to different web-apps hosted on the same server (I'm not speaking of App Engine here, but in general how webservers can be programmed).

However, browsers generally don't allow users to customize headers when going to your site, so this is not a solution most developers will use (appspot.com works this way - the Host header is used to determine which app the request should go to (that is, which subdomain of appspot.com), since the same front-end servers handle all appspot.com requests). In this way, you can have multiple web apps  on a single domain. 

On App Engine, however, you can only have one App Engine app served from your custom domain. When you set up your custom domain mapping, you do this for one project/app, and it can't be done with the same domain on multiple apps.

If you'd like to use subdomains of the domain you register serve different versions and modules of your App Engine app, you should look into the custom domains documentation

because i have ssl certificate for only 1 sub domain , 
and  don't want to buy other one ,

This means that you can only serve https connections on exactly that subdomain. Therefore, you won't be able to serve version and module subdomains as described in the doc above. You'll need to:

* buy a wildcard certificate for the subdomains that will handle versions and modules (imagine you deployed module api version v1 - you'd access it at v1-dot-api.example.appspot.com)

or

* buy a certificate with subject alternative name entries that match the specific subdomains (such as
v1-dot-api) that you'll want to use.

Finally, you can use dispatch files on App Engine to capture certain routes and send them to specific modules. So, you could deploy completely different apps to different modules, and have users access
sub.hellow.com/app1 to reach app1, and sub.hellow.com/app2 to reach app2.

can we deploy both project separately then assign then same subdomain name.?

This doesn't make sense, since a custom domain mapping will be associated with a single app.

So, the two options are:

* use custom domains version/module subdomain routing with a wildcard certificate (or subject alt name extension to your certificate)

or 

* use the dispatch file to route requests on different routes (like /app1 and /app2) to your different modules.

I hope this was helpful to you, and have a great day!
Reply all
Reply to author
Forward
0 new messages