netcore 容器内部监听设置localhost 外部无法访问

情况1

  由于localhost只能够在容器内部访问,所以在设置的时候改为*号,而不是固定ip。

情况2

  也可能由于只配置了容器和宿主机的映射,容器内部未监听端口号导致

情况3

  如果是无法连接sqlserver数据库,请检查数据库版本,liunx当中低于sqlserver 2008 sp3 会报错。

:A connection was successfully established with the server, but then an error occurred during the pre-login handshake. (provider: TCP Provider, error: 35 - An internal exception was caught)
posted @ 2023-01-06 14:57  盛开的雨季  阅读(120)  评论(0编辑  收藏  举报