diff --git a/src/Installers/Windows/GenerateNugetPackageWithMsi.ps1 b/src/Installers/Windows/GenerateNugetPackageWithMsi.ps1
new file mode 100644
index 000000000000..1b86aed1c447
--- /dev/null
+++ b/src/Installers/Windows/GenerateNugetPackageWithMsi.ps1
@@ -0,0 +1,31 @@
+# Copyright (c) .NET Foundation and contributors. All rights reserved.
+# Licensed under the MIT license. See LICENSE file in the project root for full license information.
+
+param(
+ [Parameter(Mandatory=$true)][string]$Name,
+ [Parameter(Mandatory=$true)][string]$MsiPath,
+ [Parameter(Mandatory=$false)][string]$CabPath,
+ [Parameter(Mandatory=$true)][string]$NuspecFile,
+ [Parameter(Mandatory=$true)][string]$OutputDirectory,
+ [Parameter(Mandatory=$true)][string]$Architecture,
+ [Parameter(Mandatory=$true)][string]$PackageVersion,
+ [Parameter(Mandatory=$true)][string]$RepoRoot,
+ [Parameter(Mandatory=$true)][string]$MajorVersion,
+ [Parameter(Mandatory=$true)][string]$MinorVersion
+)
+
+$NuGetDir = Join-Path $RepoRoot "obj\Tools\nuget\$Name\$Architecture"
+$NuGetExe = Join-Path $NuGetDir "nuget.exe"
+
+if (-not (Test-Path $NuGetDir)) {
+ New-Item -ItemType Directory -Force -Path $NuGetDir | Out-Null
+}
+
+if (-not (Test-Path $NuGetExe)) {
+ # Using 3.5.0 to workaround https://github.com/NuGet/Home/issues/5016
+ Write-Output "Downloading nuget.exe to $NuGetExe"
+ wget https://dist.nuget.org/win-x86-commandline/v3.5.0/nuget.exe -OutFile $NuGetExe
+}
+
+& $NuGetExe pack $NuspecFile -Version $PackageVersion -OutputDirectory $OutputDirectory -NoDefaultExcludes -NoPackageAnalysis -Properties ASPNETCORE_RUNTIME_MSI=$MsiPath`;ASPNETCORE_CAB_FILE=$CabPath`;ARCH=$Architecture`;MAJOR=$MajorVersion`;MINOR=$MinorVersion`;
+Exit $LastExitCode
\ No newline at end of file
diff --git a/src/Installers/Windows/SharedFramework/SharedFramework.wixproj b/src/Installers/Windows/SharedFramework/SharedFramework.wixproj
index 5dd1ce6809e2..0abe1a324287 100644
--- a/src/Installers/Windows/SharedFramework/SharedFramework.wixproj
+++ b/src/Installers/Windows/SharedFramework/SharedFramework.wixproj
@@ -17,6 +17,8 @@
$(SharedFrameworkHarvestRootPath)\$(Platform)\
$(DefineConstants);AspNetCoreSharedFrameworkSource=$(HarvestSource)
$(SharedFrameworkNamespaceGuid)
+ $(RepositoryRoot)\src\Installers\Windows\SharedFramework\SharedFrameworkPackage.nuspec
+ $(RepositoryRoot)artifacts/bin/$(Configuration)/installers/
@@ -47,5 +49,23 @@
+
+
+ $(InstallersOutputPath)en-US/$(TargetFileName)
+ $(InstallersOutputPath)en-US/$(Cabinet)
+
+
+
+
diff --git a/src/Installers/Windows/SharedFramework/SharedFrameworkPackage.nuspec b/src/Installers/Windows/SharedFramework/SharedFrameworkPackage.nuspec
new file mode 100644
index 000000000000..b5b8c43d9e97
--- /dev/null
+++ b/src/Installers/Windows/SharedFramework/SharedFrameworkPackage.nuspec
@@ -0,0 +1,19 @@
+
+
+
+ VS.Redist.Common.AspNetCore.SharedFramework.$ARCH$.$MAJOR$.$MINOR$
+ 1.0.0
+ VS.Redist.Common.AspNetCore.SharedFramework.$ARCH$.$MAJOR$.$MINOR$
+ Microsoft
+ Microsoft
+ https://www.microsoft.com/net/dotnet_library_license.htm
+ https://github.com/aspnet/aspnetcore
+ true
+ $MAJOR$.$MINOR$ ASP.NET Core TargetingPack ($ARCH$) Windows Installer MSI as a .nupkg for internal Visual Studio build consumption
+ © Microsoft Corporation. All rights reserved.
+
+
+
+
+
+
diff --git a/src/Installers/Windows/Wix.props b/src/Installers/Windows/Wix.props
index f2737edad203..844b72896c01 100644
--- a/src/Installers/Windows/Wix.props
+++ b/src/Installers/Windows/Wix.props
@@ -32,6 +32,7 @@
$(DefineConstants);MajorVersion=$(AspNetCoreMajorVersion)
$(DefineConstants);MinorVersion=$(AspNetCoreMinorVersion)
$(DefineConstants);PackageVersion=$(PackageVersion)
+ $(RepositoryRoot)\src\Installers\Windows\GenerateNugetPackageWithMsi.ps1