Why, when I install WebBuildTools via Visual Studio 2019 and select almost all components, are WebApplications and other web-related directories missing?

Yang, Linfeng 20 Reputation points
2025-12-17T08:53:29.86+00:00

Install in the container

command:

Start-Process "\\xxxxxxxx.com\xxxx$\SOURCE\vslayout2019\vs_setup.exe" -ArgumentList @('--quiet','--wait','--norestart','--noweb','--config','C:\webBuildTools.vsconfig','--installPath', """""""""C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools""""""""") -PassThru -Wait ; \ 
  • Screenshot after installation; some components are missingUser's image
  • Normal directory structure under normal circumstances User's image
  • .vsconfig
      {
        "version": "1.0",
        "components": [
          "Microsoft.VisualStudio.Component.Roslyn.Compiler",
          "Microsoft.VisualStudio.Component.Web",
          "Microsoft.Component.MSBuild",
          "Microsoft.Net.Component.4.7.2.TargetingPack",
          "Microsoft.Net.Component.4.8.SDK",
          "Microsoft.Net.ComponentGroup.DevelopmentPrerequisites",
          "Microsoft.VisualStudio.Component.NuGet.BuildTools",
          "Microsoft.VisualStudio.Component.TypeScript.4.3",
          "Microsoft.VisualStudio.Web.BuildTools.ComponentGroup",
          "Microsoft.Component.ClickOnce.MSBuild",
          "Microsoft.Net.Component.4.5.1.TargetingPack",
          "Microsoft.Net.Component.4.5.2.TargetingPack",
          "Microsoft.Net.Component.4.5.TargetingPack",
          "Microsoft.Net.Component.4.6.TargetingPack",
          "Microsoft.Net.Component.4.TargetingPack",
          "Microsoft.Net.ComponentGroup.TargetingPacks.Common",
          "Microsoft.VisualStudio.Component.AspNet45",
          "Microsoft.VisualStudio.Component.DockerTools.BuildTools",
          "Microsoft.VisualStudio.Component.TestTools.BuildTools",
          "Microsoft.VisualStudio.Component.WebDeploy",
          "Microsoft.VisualStudio.Wcf.BuildTools.ComponentGroup",
          "Microsoft.Net.Component.3.5.DeveloperTools",
          "Microsoft.Net.Component.4.6.1.TargetingPack",
          "Microsoft.Net.Component.4.6.2.TargetingPack",
          "Microsoft.Net.Component.4.7.1.TargetingPack",
          "Microsoft.Net.Component.4.7.TargetingPack",
          "Microsoft.Net.Component.4.8.TargetingPack",
          "Microsoft.Net.ComponentGroup.4.6.1.DeveloperTools",
          "Microsoft.Net.ComponentGroup.4.6.2.DeveloperTools",
          "Microsoft.Net.ComponentGroup.4.7.1.DeveloperTools",
          "Microsoft.Net.ComponentGroup.4.7.DeveloperTools",
          "Microsoft.Net.ComponentGroup.4.8.DeveloperTools",
          "Microsoft.Net.Core.Component.SDK.2.1",
          "Microsoft.NetCore.Component.Runtime.3.1",
          "Microsoft.NetCore.Component.Runtime.5.0",
          "Microsoft.NetCore.Component.SDK"
        ]
      }
    
Developer technologies | Visual Studio | Setup
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Gade Harika (INFOSYS LIMITED) 2,175 Reputation points Microsoft External Staff
    2025-12-18T11:09:30.4833333+00:00

    Thanks for reaching out.

    You installed Visual Studio 2019 Build Tools in a container with --noweb and a .vsconfig that lists individual components. The Build Tools SKU only brings MSBuild + minimal targets. The MSBuild folders you expect (e.g. C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\MSBuild\Microsoft\VisualStudio\v16.0\WebApplications, Web, WCF) are delivered by the Web Build Tools workload and its component group. If your offline layout doesn’t contain those packages and --noweb blocks downloading, the installer completes without those directories.

    • Workload/component IDs for Build Tools (including Web Build Tools and Web build component group) are documented here: Microsoft.VisualStudio.Workload.WebBuildTools, Microsoft.VisualStudio.Web.BuildTools.ComponentGroup. [devblogs.m...rosoft.com]
    • Installing Build Tools in Windows containers requires providing all needed payloads (or allowing downloads). Using --noweb with an incomplete layout omits components. [visualstud...gazine.com]

    1) Rebuild your offline layout to include Web build targets
    vs_buildtools.exe ^

      --layout \share\vslayout2019 ^

      --lang en-US ^

      --add Microsoft.VisualStudio.Workload.WebBuildTools ^

      --add Microsoft.VisualStudio.Web.BuildTools.ComponentGroup ^

      --includeRecommended
    Then install from that layout (omit --noweb unless the layout is complete):
    Start-Process "\share\vslayout2019\vs_buildtools.exe" -ArgumentList @(

      '--quiet','--wait','--norestart',

      '--installPath',"C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools",

      '--add','Microsoft.VisualStudio.Workload.WebBuildTools',

      '--add','Microsoft.VisualStudio.Web.BuildTools.ComponentGroup'

    ) -Wait
    Using an offline layout is the supported way to install Visual Studio without internet; the layout must contain all required packages or the install will try to fetch them unless you use --noWeb with a complete layout + --channelURI. [magnetism.ai]

    2) Container install (Dockerfile example)

    escape=`

    FROM mcr.microsoft.com/windows/servercore:ltsc2019

    SHELL ["cmd","/S","/C"]

    ADD https://aka.ms/vs/16/release/vs_buildtools.exe C:\TEMP\vs_buildtools.exe

    RUN C:\TEMP\vs_buildtools.exe --quiet --wait --norestart ^

        --add Microsoft.VisualStudio.Workload.WebBuildTools ^

        --add Microsoft.VisualStudio.Web.BuildTools.ComponentGroup ^

        --includeRecommended ^

        --installPath "C:\BuildTools" || IF "%ERRORLEVEL%"=="3010" EXIT 0

    This follows Microsoft’s Build Tools in containers guidance; include the workloads you need, and ensure base image compatibility. [visualstud...gazine.com], [blog.ndepend.com]

    **
    Why your .vsconfig wasn’t enough** Your .vsconfig lists many individual components, but the WebApplications/Web/WCF MSBuild targets are bundled in workloads/component groups (not always pulled by individual component IDs). Add the workload IDs shown above to the layout/installer to pull the correct MSBuild targets. [devblogs.m...rosoft.com]

    **
    References**

    Let us know if the issue persists after following these steps. I’ll be happy to assist further if needed. If the issue has been resolved, Kindly mark the provided solution as "Accept Answer", so that others in the community facing similar issues can easily find the solution. Your contribution is highly appreciated.

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.