The issue that I am encountering is that when I start a .NET Core project with Docker, the Microsoft SQL Server which runs locally (not as a container) cannot be found. The response of Swagger UI is displayed below.
TypeError: NetworkError when attempting to fetch resource.
This is my connection string
Server=host.docker.internal,1433;Database=myDb;User ID=myUser;Password=myPassword;Encrypt=False;MultipleActiveResultSets=True;TrustServerCertificate=True;
I have enabled TCP/IP for MSSQLSERVER, I have set 1433 as TCP port and I have disabled Windows Firewall for Domain Networks.
Should I modify anything else in the docker-compose.override.yaml file (maybe something related to environment) ?
NOTE: In my SQL Server Network Configuration, I see SQLEXPRESS instead of MSSQLSERVER. Could somehow this affect the situation ?