Execute "docker run" through powershell script

Hi,

I have been searching for a way to execute a Docker run in a Powershell script, i.e. something in the lines off:

Start-Process ([docker.exe, “docker run -v … -t …”])

The purposes of putting my Docker run in a Powershell script is so I can use the Windows 10 scheduler in order for it to run my container (having a Ubunutu 18.04 base images with a bunch of bash scripts) which will perform a set of infrastructure process tasks.

Can anyone point me in the right direction of getting this done?

Sincerely,
/swepab

How about this?

$DockerDesktopPath = "C:\Program Files\Docker\Docker\Docker Desktop.exe"

Write-Host -ForegroundColor Green 'Starting Docker Desktop'
Start-Process $DockerDesktopPath
$id = (Get-Process 'Docker Desktop').id
Wait-Process -id $id

docker start $ContainerName
docker wait $ContainerName`