-> Connect to a Red Hat Enterprise Linux 8 Azure Virtual machine using Putty,

-> Enable Docker CE Repository,
Sudo dnf config-manager --add-repo=https://download.docker.com/linux/centos/docker-ce.repo

-> Install Docker CE using dnf command,
sudo dnf list docker-ce
sudo dnf install docker-ce --nobest -y


-> After installation, Start and enable docker service,
sudo systemctl start docker
sudo systemctl enable docker
docker --version

-> Pull the SQL Server 2019 image,
sudo docker pull mcr.microsoft.com/mssql/server:2019-latest


-> Execute the container,
sudo docker run -e "ACCEPT_EULA=Y" -e "SA_PASSWORD=Pa$$w0rd1*=Pa$$w0rd1*" \
-p 1433:1433 --name jb-prd-sql1 \
-d mcr.microsoft.com/mssql/server:2019-latest

-> Verify the container,
sudo docker ps -a

-> Enter the container,
sudo docker exec -it jb-prd-sql1 "bash"

-> Connect to SQL Server Instance,
/opt/mssql-tools/bin/sqlcmd -S localhost -U SA -P "Pa$$w0rd1*=Pa$$w0rd1*"
Thank You,
Vivek Janakiraman
Disclaimer:
The views expressed on this blog are mine alone and do not reflect the views of my company or anyone else. All postings on this blog are provided “AS IS” with no warranties, and confers no rights.