Skip to content

Commit 3978c31

Browse files
authored
ci: clean up disk space before build and skip windows port forward (#4109)
* clean up disk space before build * skip portforward e2e in windows
1 parent 2aa70b3 commit 3978c31

File tree

10 files changed

+76
-18
lines changed

10 files changed

+76
-18
lines changed

.pipelines/containers/container-template.yaml

Lines changed: 28 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,38 @@ steps:
1515
1616
- script: |
1717
set -e
18+
echo "Disk space before cleanup..."
19+
df -h /
20+
echo "Removing unnecessary files to free up disk space..."
21+
sudo rm -rf \
22+
/opt/hostedtoolcache \
23+
/opt/google/chrome \
24+
/opt/microsoft/msedge \
25+
/opt/microsoft/powershell \
26+
/opt/pipx \
27+
/usr/lib/mono \
28+
/usr/local/julia* \
29+
/usr/local/lib/android \
30+
/usr/local/lib/node_modules \
31+
/usr/local/share/chromium \
32+
/usr/local/share/powershell \
33+
/usr/share/dotnet \
34+
/usr/share/swift
35+
echo "Disk space after cleanup..."
36+
df -h /
37+
displayName: "Clean up disk space"
38+
39+
- script: |
40+
set -e
41+
echo "=== Disk space BEFORE make image ==="
42+
df -h
1843
if [ ${{ parameters.os }} = 'windows' ]; then export BUILDX_ACTION='--push'; fi
1944
make ${{ parameters.name }}-image OS=${{ parameters.os }} ARCH=${{ parameters.arch }}
45+
echo "=== Disk space AFTER make image ==="
46+
df -h
2047
name: image_build
2148
displayName: Image Build
22-
retryCountOnTaskFailure: 3
49+
retryCountOnTaskFailure: 2
2350

2451
- task: AzureCLI@2
2552
displayName: "Logout"

.pipelines/pipeline.yaml

Lines changed: 40 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -148,14 +148,6 @@ stages:
148148
arch: amd64
149149
name: ipv6-hp-bpf
150150
os: linux
151-
npm_linux_amd64:
152-
arch: amd64
153-
name: npm
154-
os: linux
155-
npm_windows_amd64:
156-
arch: amd64
157-
name: npm
158-
os: windows
159151
steps:
160152
- template: containers/container-template.yaml
161153
parameters:
@@ -193,6 +185,45 @@ stages:
193185
arch: arm64
194186
name: ipv6-hp-bpf
195187
os: linux
188+
steps:
189+
- template: containers/container-template.yaml
190+
parameters:
191+
arch: $(arch)
192+
name: $(name)
193+
os: $(os)
194+
195+
- stage: containerize_npm
196+
displayName: Build NPM Images
197+
dependsOn:
198+
- setup
199+
jobs:
200+
- job: containerize_npm_amd64
201+
displayName: Build NPM Images
202+
pool:
203+
name: "$(BUILD_POOL_NAME_LINUX_AMD64)"
204+
strategy:
205+
matrix:
206+
npm_linux_amd64:
207+
arch: amd64
208+
name: npm
209+
os: linux
210+
npm_windows_amd64:
211+
arch: amd64
212+
name: npm
213+
os: windows
214+
steps:
215+
- template: containers/container-template.yaml
216+
parameters:
217+
arch: $(arch)
218+
name: $(name)
219+
os: $(os)
220+
os_version: $(os_version)
221+
- job: containerize_npm_linux_arm64
222+
displayName: Build NPM Images
223+
pool:
224+
name: "$(BUILD_POOL_NAME_LINUX_ARM64)"
225+
strategy:
226+
matrix:
196227
npm_linux_arm64:
197228
arch: arm64
198229
name: npm
@@ -244,7 +275,7 @@ stages:
244275
- stage: publish_npm
245276
displayName: Publish NPM Multiarch Manifest
246277
dependsOn:
247-
- containerize
278+
- containerize_npm
248279
jobs:
249280
- job: npm_manifest
250281
displayName: Compile NPM Manifest

.pipelines/singletenancy/aks-swift/e2e-job-template.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ stages:
7171
dependsOn: ${{ parameters.name }}
7272
datapath: true
7373
dns: true
74-
portforward: true
74+
portforward: ${{ eq(parameters.os, 'linux') }} # Unblock Pipeline, broken for all windows scenarios
7575
hostport: true
7676
service: true
7777

.pipelines/singletenancy/aks-swift/e2e.stages.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ stages:
7676
dependsOn: ${{ parameters.name }}
7777
datapath: true
7878
dns: true
79-
portforward: true
79+
portforward: ${{ eq(parameters.os, 'linux') }} # Unblock Pipeline, broken for all windows scenarios
8080
hostport: true
8181
service: true
8282

.pipelines/singletenancy/aks/e2e-job-template.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ stages:
7474
os: ${{ parameters.os }}
7575
datapath: true
7676
dns: true
77-
portforward: true
77+
portforward: ${{ eq(parameters.os, 'linux') }} # Unblock Pipeline, broken for all windows scenarios
7878
hybridWin: true
7979
service: true
8080
hostport: true

.pipelines/singletenancy/aks/e2e.stages.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ stages:
8080
os: ${{ parameters.os }}
8181
datapath: true
8282
dns: true
83-
portforward: true
83+
portforward: ${{ eq(parameters.os, 'linux') }} # Unblock Pipeline, broken for all windows scenarios
8484
hybridWin: true
8585
service: true
8686
hostport: true

.pipelines/singletenancy/azure-cni-overlay-stateless/azure-cni-overlay-stateless-e2e-job-template.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ stages:
7272
dependsOn: ${{ parameters.name }}_windows
7373
datapath: true
7474
dns: true
75-
portforward: true
75+
portforward: false # Unblock Pipeline, as stateless is tested in windows, broken for all windows scenarios
7676
hostport: true
7777
service: true
7878
hybridWin: true

.pipelines/singletenancy/azure-cni-overlay-stateless/azure-cni-overlay-stateless-e2e.stages.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ stages:
7878
dependsOn: ${{ parameters.name }}_windows
7979
datapath: true
8080
dns: true
81-
portforward: true
81+
portforward: false # Unblock Pipeline, as stateless is tested in windows, broken for all windows scenarios
8282
hostport: true
8383
service: true
8484
hybridWin: true

.pipelines/singletenancy/azure-cni-overlay/azure-cni-overlay-e2e-job-template.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ stages:
7171
dependsOn: ${{ parameters.name }}_${{ parameters.os }}
7272
datapath: true
7373
dns: true
74-
portforward: true
74+
portforward: ${{ eq(parameters.os, 'linux') }} # Unblock Pipeline, broken for all windows scenarios
7575
hostport: true
7676
service: true
7777
hybridWin: ${{ eq(parameters.os, 'windows') }}

.pipelines/singletenancy/azure-cni-overlay/azure-cni-overlay-e2e.stages.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ stages:
7777
dependsOn: ${{ parameters.name }}_${{ parameters.os }}
7878
datapath: true
7979
dns: true
80-
portforward: true
80+
portforward: ${{ eq(parameters.os, 'linux') }} # Unblock Pipeline, broken for all windows scenarios
8181
hostport: true
8282
service: true
8383
hybridWin: ${{ eq(parameters.os, 'windows') }}

0 commit comments

Comments
 (0)