ASP.NET 5 ships with support for 3 different servers:
Microsoft.AspNet.Server.IIS
Microsoft.AspNet.Server.WebListener (WebListener)
Microsoft.AspNet.Server.Kestrel (Kestrel)
You can configure your application to be hosted by any or all of these servers by specifying commands in your project.json file.
When launching a server, you can provide it with some configuration options. This can be done directly using command line parameters, or a configuration file containing the settings can be specified. The Microsoft.AspNet.Hosting command supports parameters for the server to use (such as Kestrel or WebListener) as well as a server.urls configuration key, which should contain a semicolon-separated list of URL prefixes the server should handle.
The project.json file demonstrates how to pass the server.urls parameter directly:
"kestrel": "Microsoft.AspNet.Hosting --server Kestrel --server.urls http://localhost:5004"
Alternately, a configuration file can be referenced, instead:
"kestrel": "Microsoft.AspNet.Hosting --config hosting.ini"
Then, hosting.ini can include the settings the server will use (including the server parameter, as well):
server=Kestrel
server.urls=http://localhost:5000
Reference and more detailed information here:
http://docs.asp.net/en/latest/fundamentals/servers.html
Also, the Configure() method in new Startup class allows specifying which handler to use and you can specify
app.UseIISPlatformHandler()
with appropriate parameters to use IIS hosting.
Your application is most likely running under IIS (express) hosting because you might have IIS or IIS Express selected in the "Run" option (in the toolbar at the top in Visual Studio). If you want to use Kestrel, change that to "web" and then it will pick what's specified in the project.json configuration under command->web.