Simpley create a SQL server container.
docker-compose -f docker-compose-mssql.yml up -d
Create a SQL server container and override command
to execute an init SQL script via sqlcmd
.
docker-compose -f docker-compose-mssql.yml -f docker-compose-mssql-init-cmd.yml up -d
Create a SQL server container and an mssql-tools
container to execute an init SQL script via sqlcmd
.
docker-compose -f docker-compose-mssql.yml -f docker-compose-mssql-init-tools.yml up -d
Create a SQL server container and a dotnet/sdk
container to execute SqlPackage
to restore a bacpac
.
docker-compose -f docker-compose-mssql.yml -f docker-compose-mssql-init-bacpac.yml up -d
Note:
azure-sql-edge
used to be the only option to runmssql
onarm
macs. Now, thanks to x86_64/amd64 Rosetta emulation on Apple Silicon, we can use the full version. Read about it here. If you want though, you can still useazure-sql-edge
using the details below.
The azure-sql-edge
image which contains a special version of SQL Server designed for IoT/Edge computing which can run on arm
. There are some unsupported features to be aware of, but is good enough for dev.
docker-compose -f docker-compose-mssql.yml -f docker-compose-mssql-arm.yml up -d
After creating an mssql container for the first time, you might want to set the following settings. Reference 🔗
Disable Telemetry
/opt/mssql/bin/mssql-conf set telemetry.customerfeedback false
View Current Config
cat /var/opt/mssql/mssql.conf