简体   繁体   中英

Subdomains in Play 2.0

Is it possible work with subdomains in Play 2.0 conf/routes? Like Play 1.1:

GET    {client}.mysoftware.com/         Application.index

How I can work with subdomains in my Play 2.0 app?

子域配置不是在Play级别完成,而是在反向代理级别完成。

Unfortunately not.

Here's the definition of a route:

case class Route(verb: HttpVerb, path: PathPattern, call: HandlerCall) extends Positional

It accepts the verb (eg GET ), the path component (ie not the domain or port, but only the path component) and the handler.

The definition of PathPattern can be found here , and as far as I can see, it doesn't cater for domain nor port.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM