Docker Community Forums

Share and learn in the Docker community.

Shutting down Docker Desktop on Windows 10 programmatically

Hi, quick question: Does anyone on Windows have experience with starting and (gracefully) stopping Docker Desktop via the command line?
I can start it in PowerShell with Start-Process 'C:\Program Files\Docker\Docker\Docker Desktop.exe' just fine, but so far the only way I found to stop it is with Stop-Process -Name 'Docker Desktop' , which just outright kills Docker Desktop. It works, but I’d prefer a graceful shutdown like you get when choosing ‘Quit Docker Desktop’ from the task icon context menu. Any ideas?