Quantcast
Channel: ASP.NET Core
Viewing all articles
Browse latest Browse all 9386

Self contained Web app - not able to change port number

$
0
0

It's hard to find documentation on what command line arguments work where, but I believe I should be able to change the "binding" used by my self contained / self hosted application by passing --urls "http://*:9001" for example. But no matter what I pass, the application still binds to localhost.

(I've also tried server.urls)

PS C:\git\music\Music> .\bin\Release\netcoreapp2.0\win10-x64\publish\Music.exe --urls http://*:5000
Hosting environment: Production
Content root path: C:\git\music\Music
Now listening on: http://localhost:5000
Application started. Press Ctrl+C to shut down.
Application is shutting down...
PS C:\git\music\Music> .\bin\Release\netcoreapp2.0\win10-x64\publish\Music.exe --urls "http://*:5001"
Hosting environment: Production
Content root path: C:\git\music\Music
Now listening on: http://localhost:5000
Application started. Press Ctrl+C to shut down.
Application is shutting down...

Edit: setting $env:ASPNETCORE_URLS="http://0.0.0.0:9001" works but shouldn't the command line version also work?


Viewing all articles
Browse latest Browse all 9386

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>