Skip to content

Commit ac1c1fd

Browse files
authored
Merge branch '202205' into 202205-centec
2 parents 5a0a8e2 + 874ca68 commit ac1c1fd

File tree

244 files changed

+31768
-3366
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

244 files changed

+31768
-3366
lines changed

.azure-pipelines/azure-pipelines-image-template.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,11 +28,13 @@ jobs:
2828
- template: .azure-pipelines/cleanup.yml@buildimage
2929
- ${{ parameters.preSteps }}
3030
- script: |
31-
BUILD_OPTIONS="$(BUILD_OPTIONS)"
31+
[ -n "$OVERRIDE_BUILD_OPTIONS" ] && OVERRIDE_BUILD_OPTIONS=$(OVERRIDE_BUILD_OPTIONS)
32+
BUILD_OPTIONS="$(BUILD_OPTIONS) $OVERRIDE_BUILD_OPTIONS"
3233
if [ -n "$(CACHE_MODE)" ] && echo $(PLATFORM_AZP) | grep -E -q "^(vs|broadcom|mellanox|marvell-armhf)$"; then
3334
CACHE_OPTIONS="SONIC_DPKG_CACHE_METHOD=$(CACHE_MODE) SONIC_DPKG_CACHE_SOURCE=/nfs/dpkg_cache/$(PLATFORM_AZP)"
34-
BUILD_OPTIONS="$(BUILD_OPTIONS) $CACHE_OPTIONS"
35+
BUILD_OPTIONS="$BUILD_OPTIONS $CACHE_OPTIONS"
3536
fi
37+
echo $BUILD_OPTIONS
3638
echo "##vso[task.setvariable variable=BUILD_OPTIONS]$BUILD_OPTIONS"
3739
displayName: "Set cache options"
3840
- checkout: self

.azure-pipelines/run-test-scheduler-template.yml

Lines changed: 95 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,10 @@ parameters:
1818
type: string
1919
default: 1
2020

21+
- name: NUM_ASIC
22+
type: number
23+
default: 1
24+
2125
- name: TEST_SET
2226
type: string
2327
default: ""
@@ -26,25 +30,81 @@ parameters:
2630
type: string
2731
default: ""
2832

29-
- name: MGMT_BRANCH
33+
- name: COMMON_EXTRA_PARAMS
3034
type: string
31-
default: master
35+
default: ""
3236

3337
- name: VM_TYPE
3438
type: string
3539
default: "ceos"
3640

37-
- name: SPECIFIED_PARAMS
41+
- name: TESTBED_NAME
3842
type: string
39-
default: "{}"
43+
default: ""
4044

41-
- name: COMMON_EXTRA_PARAMS
45+
- name: IMAGE_URL
4246
type: string
4347
default: ""
4448

45-
- name: NUM_ASIC
49+
- name: HWSKU
50+
type: string
51+
default: ""
52+
53+
- name: TEST_PLAN_TYPE
54+
type: string
55+
default: ""
56+
57+
- name: PLATFORM
58+
type: string
59+
default: ""
60+
61+
- name: SCRIPTS
62+
type: string
63+
default: ""
64+
65+
- name: FEATURES
66+
type: string
67+
default: ""
68+
69+
- name: SCRIPTS_EXCLUDE
70+
type: string
71+
default: ""
72+
73+
- name: FEATURES_EXCLUDE
74+
type: string
75+
default: ""
76+
77+
- name: REPO_NAME
78+
type: string
79+
default: ""
80+
81+
- name: MGMT_BRANCH
82+
type: string
83+
default: ""
84+
85+
- name: STOP_ON_FAILURE
86+
type: string
87+
default: ""
88+
89+
- name: RETRY_TIMES
90+
type: string
91+
default: ""
92+
93+
- name: DUMP_KVM_IF_FAIL
94+
type: string
95+
default: "True"
96+
values:
97+
- "True"
98+
- "False"
99+
100+
- name: REQUESTER
101+
type: string
102+
default: ""
103+
104+
- name: MAX_RUN_TEST_MINUTES
46105
type: number
47-
default: 1
106+
default: 480
107+
48108

49109
steps:
50110
- script: |
@@ -58,10 +118,20 @@ steps:
58118
set -e
59119
pip install PyYAML
60120
rm -f new_test_plan_id.txt
61-
python ./.azure-pipelines/test_plan.py create -t ${{ parameters.TOPOLOGY }} -o new_test_plan_id.txt --min-worker ${{ parameters.MIN_WORKER }} --max-worker ${{ parameters.MAX_WORKER }} \
62-
--test-set ${{ parameters.TEST_SET }} --kvm-build-id $(KVM_BUILD_ID) \
63-
--deploy-mg-extra-params "${{ parameters.DEPLOY_MG_EXTRA_PARAMS }}" --mgmt-branch ${{ parameters.MGMT_BRANCH }} \
64-
--vm-type ${{ parameters.VM_TYPE }} --specified-params "${{ parameters.SPECIFIED_PARAMS }}" --common-extra-params "${{ parameters.COMMON_EXTRA_PARAMS }}" --num-asic ${{ parameters.NUM_ASIC }}
121+
122+
python ./.azure-pipelines/test_plan.py create \
123+
-t ${{ parameters.TOPOLOGY }} \
124+
-o new_test_plan_id.txt \
125+
--min-worker ${{ parameters.MIN_WORKER }} \
126+
--max-worker ${{ parameters.MAX_WORKER }} \
127+
--test-set ${{ parameters.TEST_SET }} \
128+
--kvm-build-id $(KVM_BUILD_ID) \
129+
--deploy-mg-extra-params "${{ parameters.DEPLOY_MG_EXTRA_PARAMS }}" \
130+
--mgmt-branch ${{ parameters.MGMT_BRANCH }} \
131+
--vm-type ${{ parameters.VM_TYPE }} \
132+
--common-extra-params "${{ parameters.COMMON_EXTRA_PARAMS }}" \
133+
--num-asic ${{ parameters.NUM_ASIC }}
134+
65135
TEST_PLAN_ID=`cat new_test_plan_id.txt`
66136
67137
echo "Created test plan $TEST_PLAN_ID"
@@ -107,18 +177,20 @@ steps:
107177
env:
108178
TESTBED_TOOLS_URL: $(TESTBED_TOOLS_URL)
109179
displayName: Run test
110-
111-
- script: |
112-
set -e
113-
echo "KVM dump"
114-
echo "SONiC PR system-level test is powered by SONiC Elastictest, for any issue, please send email to [email protected]"
115-
echo "Runtime detailed progress at $(FRONTEND_URL)/scheduler/testplan/$TEST_PLAN_ID "
116-
# When "KVMDUMP" finish, it changes into "FAILED", "CANCELLED" or "FINISHED"
117-
python ./.azure-pipelines/test_plan.py poll -i "$(TEST_PLAN_ID)" --expected-state KVMDUMP
118-
condition: succeededOrFailed()
119-
env:
120-
TESTBED_TOOLS_URL: $(TESTBED_TOOLS_URL)
121-
displayName: KVM dump
180+
timeoutInMinutes: ${{ parameters.MAX_RUN_TEST_MINUTES }}
181+
182+
- ${{ if eq(parameters.DUMP_KVM_IF_FAIL, 'True') }}:
183+
- script: |
184+
set -e
185+
echo "KVM dump"
186+
echo "SONiC PR system-level test is powered by SONiC Elastictest, for any issue, please send email to [email protected]"
187+
echo "Runtime detailed progress at $(FRONTEND_URL)/scheduler/testplan/$TEST_PLAN_ID "
188+
# When "KVMDUMP" finish, it changes into "FAILED", "CANCELLED" or "FINISHED"
189+
python ./.azure-pipelines/test_plan.py poll -i "$(TEST_PLAN_ID)" --expected-state KVMDUMP
190+
condition: succeededOrFailed()
191+
env:
192+
TESTBED_TOOLS_URL: $(TESTBED_TOOLS_URL)
193+
displayName: KVM dump
122194
123195
- script: |
124196
set -e

azure-pipelines.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ resources:
2626
- repository: sonic-mgmt
2727
type: github
2828
name: sonic-net/sonic-mgmt
29+
ref: master
2930
endpoint: sonic-net
3031
- repository: buildimage
3132
type: github

build_debian.sh

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ sudo LANG=C chroot $FILESYSTEM_ROOT mount
108108
[ -d $TRUSTED_GPG_DIR ] && [ ! -z "$(ls $TRUSTED_GPG_DIR)" ] && sudo cp $TRUSTED_GPG_DIR/* ${FILESYSTEM_ROOT}/etc/apt/trusted.gpg.d/
109109

110110
## Pointing apt to public apt mirrors and getting latest packages, needed for latest security updates
111-
scripts/build_mirror_config.sh files/apt $CONFIGURED_ARCH $IMAGE_DISTRO
111+
scripts/build_mirror_config.sh files/apt $CONFIGURED_ARCH $IMAGE_DISTRO
112112
sudo cp files/apt/sources.list.$CONFIGURED_ARCH $FILESYSTEM_ROOT/etc/apt/sources.list
113113
sudo cp files/apt/apt.conf.d/{81norecommends,apt-{clean,gzip-indexes,no-languages},no-check-valid-until} $FILESYSTEM_ROOT/etc/apt/apt.conf.d/
114114

@@ -280,7 +280,7 @@ then
280280
## Install Kubernetes master
281281
echo '[INFO] Install kubernetes master'
282282
install_kubernetes ${MASTER_KUBERNETES_VERSION}
283-
283+
284284
sudo https_proxy=$https_proxy LANG=C chroot $FILESYSTEM_ROOT curl -fsSL \
285285
https://packages.microsoft.com/keys/microsoft.asc | \
286286
sudo LANG=C chroot $FILESYSTEM_ROOT apt-key add -
@@ -295,7 +295,7 @@ then
295295
sudo LANG=C chroot $FILESYSTEM_ROOT apt-get -y remove gnupg
296296
sudo https_proxy=$https_proxy LANG=C chroot $FILESYSTEM_ROOT curl -o /tmp/cri-dockerd.deb -fsSL \
297297
https://github.com/Mirantis/cri-dockerd/releases/download/v${MASTER_CRI_DOCKERD}/cri-dockerd_${MASTER_CRI_DOCKERD}.3-0.debian-${IMAGE_DISTRO}_amd64.deb
298-
sudo LANG=C chroot $FILESYSTEM_ROOT apt-get -y install -f /tmp/cri-dockerd.deb
298+
sudo LANG=C chroot $FILESYSTEM_ROOT apt-get -y install -f /tmp/cri-dockerd.deb
299299
sudo LANG=C chroot $FILESYSTEM_ROOT rm -f /tmp/cri-dockerd.deb
300300
else
301301
echo '[INFO] Skipping Install kubernetes master'
@@ -430,6 +430,15 @@ sudo LANG=C DEBIAN_FRONTEND=noninteractive chroot $FILESYSTEM_ROOT apt-get -y in
430430
systemd-sysv \
431431
ntp
432432

433+
# Workaround for issue: The udev rule may fail to be executed because the
434+
# daemon-reload command is executed in parallel
435+
# Github issue: https://github.com/systemd/systemd/issues/24668
436+
# Github PR: https://github.com/systemd/systemd/pull/24673
437+
# This workaround should be removed after a upstream already contains the fixes
438+
sudo patch $FILESYSTEM_ROOT/lib/systemd/system/systemd-udevd.service \
439+
files/image_config/systemd/systemd-udevd/fix-udev-rule-may-fail-if-daemon-reload-command-runs.patch
440+
441+
433442
if [[ $CONFIGURED_ARCH == amd64 ]]; then
434443
sudo LANG=C DEBIAN_FRONTEND=noninteractive chroot $FILESYSTEM_ROOT apt-get -y download \
435444
grub-pc-bin
@@ -512,6 +521,9 @@ sudo https_proxy=$https_proxy LANG=C chroot $FILESYSTEM_ROOT pip3 install 'docke
512521
# Install scapy
513522
sudo https_proxy=$https_proxy LANG=C chroot $FILESYSTEM_ROOT pip3 install 'scapy==2.4.4'
514523

524+
# The option --no-build-isolation can be removed when upgrading PyYAML to 6.0.1
525+
sudo https_proxy=$https_proxy LANG=C chroot $FILESYSTEM_ROOT pip3 install 'PyYAML==5.4.1' --no-build-isolation
526+
515527
## Note: keep pip installed for maintainance purpose
516528

517529
# Install GCC, needed for building/installing some Python packages

device/arista/x86_64-arista_7050_qx32/platform.json

Lines changed: 35 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,17 @@
11
{
22
"chassis": {
33
"name": "DCS-7050QX-32",
4-
"components": [],
4+
"components": [
5+
{
6+
"name": "Scd(addr=0000:04:00.0)"
7+
},
8+
{
9+
"name": "Ucd90120A(addr=6-004e)"
10+
},
11+
{
12+
"name": "Ucd90160(addr=10-004e)"
13+
}
14+
],
515
"fans": [
616
{
717
"name": "fan1"
@@ -53,37 +63,43 @@
5363
"psus": [
5464
{
5565
"name": "psu1",
56-
"fans": []
66+
"fans": [
67+
{
68+
"name": "psu1/1",
69+
"speed": {
70+
"controllable": false
71+
}
72+
}
73+
]
5774
},
5875
{
5976
"name": "psu2",
60-
"fans": []
77+
"fans": [
78+
{
79+
"name": "psu2/1",
80+
"speed": {
81+
"controllable": false
82+
}
83+
}
84+
]
6185
}
6286
],
6387
"thermals": [
6488
{
65-
"name": "Cpu temp sensor"
66-
},
67-
{
68-
"name": "Board sensor"
69-
},
70-
{
71-
"name": "Front-panel temp sensor"
72-
},
73-
{
74-
"name": "Rear temp sensor"
75-
},
76-
{
77-
"name": "Power supply 1 inlet temp sensor"
89+
"name": "Cpu temp sensor",
90+
"controllable": false
7891
},
7992
{
80-
"name": "Power supply 1 internal sensor"
93+
"name": "Board sensor",
94+
"controllable": false
8195
},
8296
{
83-
"name": "Power supply 2 inlet temp sensor"
97+
"name": "Front-panel temp sensor",
98+
"controllable": false
8499
},
85100
{
86-
"name": "Power supply 2 internal sensor"
101+
"name": "Rear temp sensor",
102+
"controllable": false
87103
}
88104
],
89105
"sfps": [

0 commit comments

Comments
 (0)