Skip to content

Instantly share code, notes, and snippets.

@andrewabest
Last active January 15, 2018 05:57
Show Gist options
  • Save andrewabest/85bc85d2eb64fe16faa1a3e6aaffc635 to your computer and use it in GitHub Desktop.
Save andrewabest/85bc85d2eb64fe16faa1a3e6aaffc635 to your computer and use it in GitHub Desktop.
SQL Server on Linux Docker local dev
ECHO OFF
docker stop mssql-myproj-dev
docker rm mssql-myproj-dev
ECHO OFF
docker inspect --type=image microsoft/mssql-server-linux
IF ERRORLEVEL 1 (
docker pull microsoft/mssql-server-linux
)
docker run -d --name mssql-myproj-dev -e ACCEPT_EULA=Y -e SA_PASSWORD=Password$1 -e MSSQL_PID=Express -p 1434:1433 microsoft/mssql-server-linux:latest
docker attach mssql-myproj-dev
docker run -v "$(Get-Location)/.mssql-data:/var/opt/mssql" -e "ACCEPT_EULA=Y" -e "SA_PASSWORD=SqlServer2017" -p 1433:1433 -d microsoft/mssql-server-linux:latest
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment