Route my service object as a subdomain instead of path

Hi,
I am using kong 1.1.x latest version. Is there a way to route my service using subdomain instead of path.
Instead of https://example.com/service1 I could route my service as https://service1.example.com when I access it in the browser.
Thanks

You can set up a wild-card DNS to *.example.com and then use custom nginx template to route https://service1.example.com to your desired destination.

I tried using the wild-card in route but, when I access the dns (subdomain.example.com) in the browser the dns is not detected. btw,
this hostname (example.com) is map in etc/hosts. So I am thinking if that is why the wild-card dns does not match. Thanks