Skip to content

Commit c2f45ac

Browse files
arroycjviau
andauthored
Trim FunctionsNetHost artifacts (#10364) (#10366)
Co-authored-by: Jacob Viau <[email protected]>
1 parent 27a14df commit c2f45ac

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

build/build-extensions.ps1

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@ function BuildRuntime([string] $targetRid, [bool] $isSelfContained) {
6868

6969
Write-Host ""
7070
$symbols = Get-ChildItem -Path $publishTarget -Filter *.pdb
71+
$symbols += Get-ChildItem -Path "$publishTarget\workers\dotnet-isolated\*" -Include "*.pdb", "*.dbg" -Recurse
7172
Write-Host "Zipping symbols: $($symbols.Count) symbols found"
7273

7374
$symbolsPath = "$publishDir\Symbols"
@@ -107,6 +108,13 @@ function CleanOutput([string] $rootPath) {
107108
ForEach-Object { Get-ChildItem "$($_.FullName)\runtimes" -Directory -Exclude $keepRuntimes } |
108109
Remove-Item -Recurse -Force -ErrorAction SilentlyContinue
109110

111+
Write-Host " Removing FunctionsNetHost(linux executable) and dependencies from dotnet-isolated worker"
112+
$dotnetIsolatedBinPath = Join-Path $rootPath "workers\dotnet-isolated\bin"
113+
if (Test-Path $dotnetIsolatedBinPath) {
114+
Remove-Item -Path (Join-Path $dotnetIsolatedBinPath "FunctionsNetHost") -ErrorAction SilentlyContinue
115+
Get-ChildItem -Path $dotnetIsolatedBinPath -Filter "*.so" | Remove-Item -ErrorAction SilentlyContinue
116+
}
117+
110118
Write-Host " Current size: $(GetFolderSizeInMb $rootPath) Mb"
111119
}
112120

0 commit comments

Comments
 (0)