Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Use Invoke-ExecuteNotebook to build a SQL-on-Linux instance in a Docker container, by calling Invoke-ExecuteNotebook to execute the Notebook, and passing in the sa_password & digits for the name/port number to the Notebook as a parameter.
<# Download the PowerShellNotebook Module from the PowerShell Gallery #>
try {Import-Module PowerShellNotebook -ErrorAction Stop} catch {Install-Module -Name PowerShellNotebook -Scope CurrentUser} finally {Import-Module PowerShellNotebook}
Import-Module PowerShellNotebook;
<# Download the Jupyter Notebook in this Gist #>
Invoke-RestMethod -OutFile SQL-on-Docker-with-PowerShell.ipynb
<# OK, you should now be ready to move onto the steps in Build_SQLInstance_wStringCreds.ps1
Please note: you're going to need to have Docker Desktop installed & running for all this to work #>
Invoke-ExecuteNotebook -InputNotebook .\SQL-on-Docker-with-PowerShell.ipynb -Parameters @{sa_password = 'Test9999'; SQLNumber = 97}
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment