Ritu Singh
Solution
The following steps will help you connect the SQL Server to the Docker container.
In your running container of the web server, start an interactive bash shell.
After this you need to install mssql-tools (refer to this>> >doc)
Lastly, you need to connect to the SQL Server instance by using the following command:
where the internal port is 1433 and the internal IP address assigned to the database in Docker is 172.23.0.2. The database container has a self-signed certificate, so I had to use the -No option; otherwise, I get the following error:
Add 2 connection properties in the .env file in Laravel
The same goes for the database.php file
Eventually, after launching my containers, I was able to connect to SQL Server Management Studio using the connection panel's parameters:
server name = localhost,5434
disable encryption
trust server certificate
where 5434 is the port exposed out of the db container see docker-compose file
Read more:
>Use Firebase Realtime Database with ASP.NET MVC App
>Setting up a Cloud Composer environment: Step-by-step guide
>Testing react components using Hooks and Mocks
>Plugins and Presets for Vuejs project
>How to Create an array based on two other arrays in Php
>Built Web API using ASP.NET (C#)