Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions build_container/build_container_windows.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,22 @@ function RunAndCheckError
echo "done."
}

function DisableService
{
param([string] $serviceName)

echo "Disabling service '$serviceName'"
Set-Service -Name $serviceName -StartupType Disabled
Stop-Service -Force -Name $serviceName
}

DisableService DiagTrack
DisableService LanmanWorkstation
DisableService MSDTC
DisableService SysMain
DisableService usosvc
DisableService WinRM

# Ensures paths rooted at /c/ can be found by programs running via msys2 shell
RunAndCheckError "cmd.exe" @("/s", "/c", "mklink /D C:\c C:\")

Expand Down