@@ -9,6 +9,8 @@ $rootDir = Split-Path -Parent $currentDir
9
9
$buildOutput = Join-Path $rootDir " buildoutput"
10
10
$hasSuffix = ! [string ]::IsNullOrEmpty($suffix )
11
11
12
+ $extensionVersionNoSuffix = $extensionVersion
13
+
12
14
if ($hasSuffix ) {
13
15
$extensionVersion = " $extensionVersion -$suffix "
14
16
}
@@ -110,12 +112,20 @@ function CleanOutput([string] $rootPath) {
110
112
function CreateSiteExtensions () {
111
113
$stopwatch = [System.Diagnostics.Stopwatch ]::StartNew()
112
114
$siteExtensionPath = " $buildOutput \temp_extension"
115
+
116
+ # The official site extension needs to be nested inside a folder with its version.
117
+ # Not using the suffix (eg: '-ci') here as it may not work correctly in a private stamp
118
+ $officialSiteExtensionPath = " $siteExtensionPath \$extensionVersionNoSuffix "
113
119
114
120
Write-Host " ======================================"
115
121
Write-Host " Copying build to temp directory to prepare for zipping official site extension."
116
- Copy-Item - Path $buildOutput \publish\win- x86\ - Destination $siteExtensionPath \32bit - Force - Recurse > $null
117
- Copy-Item - Path $buildOutput \publish\win- x64 - Destination $siteExtensionPath \64bit - Force - Recurse > $null
118
- Copy-Item - Path $siteExtensionPath \32bit\applicationHost.xdt - Destination $siteExtensionPath - Force > $null
122
+ Copy-Item - Path $buildOutput \publish\win- x86\ - Destination $officialSiteExtensionPath \32bit - Force - Recurse > $null
123
+ Copy-Item - Path $buildOutput \publish\win- x64 - Destination $officialSiteExtensionPath \64bit - Force - Recurse > $null
124
+ Copy-Item - Path $officialSiteExtensionPath \32bit\applicationHost.xdt - Destination $officialSiteExtensionPath - Force > $null
125
+
126
+ # This goes in the root dir
127
+ Copy-Item $rootDir \src\WebJobs.Script.WebHost\extension.xml $siteExtensionPath > $null
128
+
119
129
Write-Host " Done copying. Elapsed: $ ( $stopwatch.Elapsed ) "
120
130
Write-Host " ======================================"
121
131
Write-Host " "
0 commit comments