2021-04-07 18:05:31 -05:00
|
|
|
# The azure pipeline template for Official build, and upgrade version build
|
|
|
|
|
2021-02-24 23:44:58 -06:00
|
|
|
parameters:
|
|
|
|
- name: 'jobFilters'
|
|
|
|
type: object
|
|
|
|
default: ''
|
|
|
|
- name: 'buildOptions'
|
|
|
|
type: string
|
|
|
|
default: 'SONIC_CONFIG_BUILD_JOBS=1'
|
2021-04-07 18:05:31 -05:00
|
|
|
- name: 'preSteps'
|
|
|
|
type: stepList
|
|
|
|
default: []
|
2021-02-24 23:44:58 -06:00
|
|
|
- name: 'postSteps'
|
|
|
|
type: stepList
|
|
|
|
default: []
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
- name: 'jobGroups'
|
|
|
|
type: object
|
2021-04-22 23:56:09 -05:00
|
|
|
default: ''
|
2022-07-31 22:31:02 -05:00
|
|
|
- name: 'qemuOrCrossBuild'
|
|
|
|
type: boolean
|
|
|
|
default: false
|
2021-02-24 23:44:58 -06:00
|
|
|
|
|
|
|
jobs:
|
2021-04-07 18:05:31 -05:00
|
|
|
- template: azure-pipelines-image-template.yml
|
2021-02-24 23:44:58 -06:00
|
|
|
parameters:
|
|
|
|
jobFilters: ${{ parameters.jobFilters }}
|
2021-04-07 18:05:31 -05:00
|
|
|
preSteps: ${{ parameters.preSteps }}
|
|
|
|
postSteps: ${{ parameters.postSteps }}
|
|
|
|
jobVariables:
|
2021-04-08 18:36:53 -05:00
|
|
|
PLATFORM_AZP: $(GROUP_NAME)
|
2021-04-07 18:05:31 -05:00
|
|
|
PLATFORM_ARCH: amd64
|
2021-04-23 04:58:46 -05:00
|
|
|
BUILD_NUMBER: $(Build.BuildId)
|
2021-04-07 18:05:31 -05:00
|
|
|
BUILD_OPTIONS: ${{ parameters.buildOptions }}
|
2021-04-15 01:32:08 -05:00
|
|
|
DOCKER_DATA_ROOT_FOR_MULTIARCH: /data/march/docker
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
dbg_image: no
|
2022-07-03 19:40:04 -05:00
|
|
|
asan_image: no
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
swi_image: no
|
2021-06-21 01:12:25 -05:00
|
|
|
docker_syncd_rpc_image: no
|
|
|
|
syncd_rpc_image: no
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
platform_rpc: no
|
2022-07-31 22:31:02 -05:00
|
|
|
${{ if parameters.qemuOrCrossBuild }}:
|
|
|
|
SONIC_SLAVE_DOCKER_DRIVER: 'vfs'
|
|
|
|
CACHE_MODE: 'none'
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
${{ if ne(parameters.jobGroups, '') }}:
|
|
|
|
jobGroups: ${{ parameters.jobGroups }}
|
|
|
|
${{ if eq(parameters.jobGroups, '') }}:
|
|
|
|
jobGroups:
|
|
|
|
- name: vs
|
|
|
|
variables:
|
|
|
|
dbg_image: yes
|
2022-07-03 19:40:04 -05:00
|
|
|
asan_image: yes
|
2021-05-03 14:31:52 -05:00
|
|
|
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
- name: barefoot
|
|
|
|
variables:
|
2021-06-21 01:12:25 -05:00
|
|
|
docker_syncd_rpc_image: yes
|
2021-06-08 11:43:00 -05:00
|
|
|
platform_rpc: bfn
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
swi_image: yes
|
2021-05-03 14:31:52 -05:00
|
|
|
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
- name: broadcom
|
2022-04-07 07:04:43 -05:00
|
|
|
timeoutInMinutes: 1440
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
variables:
|
|
|
|
dbg_image: yes
|
|
|
|
swi_image: yes
|
2021-06-21 01:12:25 -05:00
|
|
|
docker_syncd_rpc_image: yes
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
platform_rpc: brcm
|
2021-05-03 14:31:52 -05:00
|
|
|
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
- name: centec
|
|
|
|
variables:
|
|
|
|
dbg_image: yes
|
2021-06-21 01:12:25 -05:00
|
|
|
docker_syncd_rpc_image: yes
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
platform_rpc: centec
|
2021-05-03 14:31:52 -05:00
|
|
|
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
- name: centec-arm64
|
2022-07-31 22:31:02 -05:00
|
|
|
${{ if not(parameters.qemuOrCrossBuild) }}:
|
|
|
|
pool: sonicbld-arm64
|
2021-08-04 03:45:38 -05:00
|
|
|
timeoutInMinutes: 2880
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
variables:
|
|
|
|
PLATFORM_ARCH: arm64
|
2021-05-03 14:31:52 -05:00
|
|
|
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
- name: generic
|
|
|
|
variables:
|
|
|
|
dbg_image: yes
|
2021-05-03 14:31:52 -05:00
|
|
|
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
- name: innovium
|
|
|
|
variables:
|
2021-06-15 18:38:02 -05:00
|
|
|
dbg_image: yes
|
2021-05-03 14:31:52 -05:00
|
|
|
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
- name: marvell-armhf
|
2022-07-31 22:31:02 -05:00
|
|
|
${{ if not(parameters.qemuOrCrossBuild) }}:
|
|
|
|
pool: sonicbld-armhf
|
2021-08-04 03:45:38 -05:00
|
|
|
timeoutInMinutes: 2880
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
variables:
|
|
|
|
PLATFORM_ARCH: armhf
|
2021-05-03 14:31:52 -05:00
|
|
|
|
2023-05-04 23:40:35 -05:00
|
|
|
- name: marvell-arm64
|
|
|
|
${{ if not(parameters.qemuOrCrossBuild) }}:
|
|
|
|
pool: sonicbld-arm64
|
|
|
|
timeoutInMinutes: 2880
|
|
|
|
variables:
|
|
|
|
PLATFORM_ARCH: arm64
|
|
|
|
|
|
|
|
- name: marvell
|
|
|
|
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
- name: mellanox
|
|
|
|
variables:
|
|
|
|
dbg_image: yes
|
2021-06-21 01:12:25 -05:00
|
|
|
docker_syncd_rpc_image: yes
|
|
|
|
syncd_rpc_image: yes
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
platform_rpc: mlnx
|
2021-05-03 14:31:52 -05:00
|
|
|
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
- name: nephos
|
|
|
|
variables:
|
|
|
|
dbg_image: yes
|
2021-06-21 01:12:25 -05:00
|
|
|
docker_syncd_rpc_image: yes
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
platform_rpc: nephos
|
2021-05-03 14:31:52 -05:00
|
|
|
|
2023-12-15 02:52:51 -06:00
|
|
|
- name: pensando
|
|
|
|
pool: sonicbld-arm64
|
|
|
|
variables:
|
|
|
|
PLATFORM_ARCH: arm64
|
|
|
|
|
2021-04-07 18:05:31 -05:00
|
|
|
buildSteps:
|
2023-02-21 23:00:06 -06:00
|
|
|
- template: .azure-pipelines/template-skipvstest.yml@buildimage
|
|
|
|
- template: .azure-pipelines/template-daemon.yml@buildimage
|
2021-04-07 18:05:31 -05:00
|
|
|
- bash: |
|
2021-05-03 14:31:52 -05:00
|
|
|
set -ex
|
2023-12-15 02:52:51 -06:00
|
|
|
if [ $(GROUP_NAME) == pensando ]; then
|
|
|
|
make $BUILD_OPTIONS target/sonic-pensando.tar
|
|
|
|
elif [ $(GROUP_NAME) == vs ]; then
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
if [ $(dbg_image) == yes ]; then
|
2021-11-17 23:01:41 -06:00
|
|
|
make $BUILD_OPTIONS INSTALL_DEBUG_TOOLS=y target/sonic-vs.img.gz
|
|
|
|
mv target/sonic-vs.img.gz target/sonic-vs-dbg.img.gz
|
2021-04-07 18:05:31 -05:00
|
|
|
fi
|
2022-07-03 19:40:04 -05:00
|
|
|
if [ $(asan_image) == yes ]; then
|
|
|
|
make $BUILD_OPTIONS ENABLE_ASAN=y target/docker-sonic-vs.gz
|
|
|
|
mv target/docker-sonic-vs.gz target/docker-sonic-vs-asan.gz
|
|
|
|
fi
|
2024-03-11 01:45:18 -05:00
|
|
|
if [ "$(K8S_MASTER_CHANGED)" == 'YES' ]; then
|
|
|
|
make $BUILD_OPTIONS INCLUDE_KUBERNETES_MASTER=y target/sonic-vs.img.gz
|
|
|
|
gzip -d target/sonic-vs.img.gz
|
|
|
|
SONIC_RUN_CMDS="qemu-img convert target/sonic-vs.img -O vhdx -o subformat=dynamic target/sonic-vs.vhdx" make $BUILD_OPTIONS sonic-slave-run
|
|
|
|
gzip target/sonic-vs.vhdx
|
|
|
|
mv target/sonic-vs.vhdx.gz target/sonic-vs-k8s.vhdx.gz
|
|
|
|
rm target/sonic-vs.img
|
Add k8s master code new (#15716)
Why I did it
Currently, k8s master image is generated from a separate branch which we created by ourselves, not release ones. We need to commit these k8s master related code to master branch for a better way to do k8s master image build out.
Work item tracking
Microsoft ADO (number only):
19998138
How I did it
Install k8s dashboard docker images
Install geneva mds and mdsd and fluentd docker images and tag them as latest, tagging latest will help create container always with the latest version
Install azure-storage-blob and azure-identity, this will help do etcd backup and restore.
Install kubernetes python client packages, this will help read worker and container state, we can send these metric to Geneva.
Remove mdm debian package, will replace it with the mdm docker image
Add k8s master entrance script, this script will be called by rc-local service when system startup. we have some master systemd services in compute-move repo, when VMM service create master VM, VMM will copy all master service files inside VM, the entrance script will setup all services according to the service files.
When the entrance script content changed, the PR build will set include_kubernetes_master=y to help do validation for k8s master related code change. The default value of include_kubernetes_master should be always n for public master branch. We will generate master image from internal master branch
How to verify it
Build with INCLUDE_KUBERNETES_MASTER = y
2023-07-24 18:44:59 -05:00
|
|
|
fi
|
2021-04-07 18:05:31 -05:00
|
|
|
make $BUILD_OPTIONS target/docker-sonic-vs.gz target/sonic-vs.img.gz target/docker-ptf.gz
|
2022-11-17 06:42:51 -06:00
|
|
|
make $BUILD_OPTIONS target/docker-ptf-sai.gz
|
2021-09-17 03:18:36 -05:00
|
|
|
if [ $(Build.Reason) != 'PullRequest' ];then
|
|
|
|
gzip -kd target/sonic-vs.img.gz
|
2023-03-27 11:58:37 -05:00
|
|
|
SONIC_RUN_CMDS="qemu-img convert target/sonic-vs.img -O vhdx -o subformat=dynamic target/sonic-vs.vhdx" make $BUILD_OPTIONS sonic-slave-run
|
2021-09-17 03:18:36 -05:00
|
|
|
rm target/sonic-vs.img
|
|
|
|
fi
|
2021-04-07 18:05:31 -05:00
|
|
|
else
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
if [ $(dbg_image) == yes ]; then
|
2021-11-17 23:01:41 -06:00
|
|
|
make $BUILD_OPTIONS INSTALL_DEBUG_TOOLS=y target/sonic-$(GROUP_NAME).bin
|
|
|
|
mv target/sonic-$(GROUP_NAME).bin target/sonic-$(GROUP_NAME)-dbg.bin
|
2021-04-07 18:05:31 -05:00
|
|
|
fi
|
[ci] Fix the boolean value case sensitive issue in Azure Pipelines (#7399)
Why I did it
Fix the boolean value case sensitive issue in Azure Pipelines
When passing parameters to a template, the "true" or "false" will have case sensitive issue, it should be a type casting issue.
To fix it, we change the true/false to yes/no, to escape the trap.
Support to override the job groups in the template, so PR build has chance to use different build parameters, only build simple targets. For example, for broadcom, we only build target/sonic-broadcom.bin, the other images, such as swi, debug bin, etc, will not be built.
2021-04-22 20:26:16 -05:00
|
|
|
if [ $(swi_image) == yes ]; then
|
2021-04-07 18:05:31 -05:00
|
|
|
make $BUILD_OPTIONS ENABLE_IMAGE_SIGNATURE=y target/sonic-aboot-$(GROUP_NAME).swi
|
|
|
|
fi
|
2021-06-21 01:12:25 -05:00
|
|
|
if [ $(docker_syncd_rpc_image) == yes ]; then
|
2022-12-01 00:26:54 -06:00
|
|
|
# workaround for issue in rules/sairedis.dep, git ls-files will list un-exist files for cache
|
2021-04-07 18:05:31 -05:00
|
|
|
make $BUILD_OPTIONS ENABLE_SYNCD_RPC=y target/docker-syncd-$(platform_rpc)-rpc.gz
|
2022-12-01 00:26:54 -06:00
|
|
|
pushd ./src/sonic-sairedis/SAI
|
|
|
|
git stash
|
|
|
|
popd
|
2022-08-24 13:42:15 -05:00
|
|
|
if [ $(GROUP_NAME) == broadcom ]; then
|
|
|
|
make $BUILD_OPTIONS ENABLE_SYNCD_RPC=y target/docker-syncd-$(platform_rpc)-dnx-rpc.gz
|
2022-12-01 00:26:54 -06:00
|
|
|
pushd ./src/sonic-sairedis/SAI
|
|
|
|
git stash
|
|
|
|
popd
|
2023-01-05 21:45:03 -06:00
|
|
|
fi
|
2021-04-07 18:05:31 -05:00
|
|
|
fi
|
2021-06-21 01:12:25 -05:00
|
|
|
if [ $(syncd_rpc_image) == yes ]; then
|
|
|
|
make $BUILD_OPTIONS ENABLE_SYNCD_RPC=y target/sonic-$(GROUP_NAME).bin
|
|
|
|
mv target/sonic-mellanox.bin target/sonic-$(GROUP_NAME)-rpc.bin
|
|
|
|
fi
|
2021-04-07 18:05:31 -05:00
|
|
|
make $BUILD_OPTIONS target/sonic-$(GROUP_NAME).bin
|
|
|
|
fi
|
2021-04-11 18:43:06 -05:00
|
|
|
displayName: "Build sonic image"
|
2023-02-21 23:00:06 -06:00
|
|
|
- template: .azure-pipelines/check-dirty-version.yml@buildimage
|