Skip to content

Instantly share code, notes, and snippets.

@greghelton
Last active May 13, 2025 23:49
Show Gist options
  • Select an option

  • Save greghelton/b22e02ddd145d4ae8672dcf1801a8d0f to your computer and use it in GitHub Desktop.

Select an option

Save greghelton/b22e02ddd145d4ae8672dcf1801a8d0f to your computer and use it in GitHub Desktop.
Setting up MS SQL Server in Docker on Mac.

% docker run --platform linux/amd64 -e "ACCEPT_EULA=Y" -e "SA_PASSWORD=your-password"
-p 1433:1433 --name sqlserver -d mcr.microsoft.com/mssql/server:2022-latest

% docker ps

% brew install --no-quarantine mssql-tools

% sqlcmd -S localhost -U sa -P 'your-password'
1> SELECT name FROM sys.databases;
2> GO
name

master
tempdb
model
msdb

(4 rows affected)
1>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment