Is it possible and permissible to have multiple proxies point to the same cloud instance?

For example, I would like nginx to serve a different site (live or test) depending on the domain with which it is accessed.

Thanks and hoping this is the right forum for such a question,

Tim