on the IPv6 loopback interface: 'Cannot assign requested address'
.netcore +docker
需要修改两个地方
Dockerfile
添加 ENV ASPNETCORE_URLS=http://+:44303
FROM mcr.microsoft.com/dotnet/aspnet:6.0 AS base ENV ASPNETCORE_URLS=http://+:44303 WORKDIR /app EXPOSE 44303
appsettings.json
"urls": "http://localhost:44303"
改为
"urls": "http://0.0.0.0:4003"