forked from sonic-net/sonic-buildimage
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add pipeline yml for nvidia-bluefield (sonic-net#90)
Why I did it Setup a build pipeline to build the image on the daily basis, and PR will also trigger build pipeline. How I did it Add new pipeline.yml for nvidia-sonic repo. Build pipeline only supports sonic-nvidia-bluefield.bin for now, and I will add support for sonic-nvidia-bluefield.tar.gz and sonic-nvidia-bluefield.bfb. How to verify it I have verified with my private repo. And when this PR is merged, I will create azure pipeline to make it work.
- Loading branch information
Showing
4 changed files
with
73 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,2 @@ | ||
variables: | ||
${{ if eq(variables['Build.Reason'],'PullRequest') }}: | ||
VERSION_CONTROL_OPTIONS: 'SONIC_VERSION_CONTROL_COMPONENTS=$([[ "$(System.PullRequest.TargetBranch)" =~ ^20[2-9][0-9]{3}$ ]] && echo deb,py2,py3,web,git,docker)' | ||
${{ elseif ne(variables['Build.SourceBranchName'],'master') }}: | ||
VERSION_CONTROL_OPTIONS: 'SONIC_VERSION_CONTROL_COMPONENTS=deb,py2,py3,web,git,docker' | ||
${{ else }}: | ||
VERSION_CONTROL_OPTIONS: '' | ||
VERSION_CONTROL_OPTIONS: '' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
# Starter pipeline | ||
# Start with a minimal pipeline that you can customize to build and deploy your code. | ||
# Add steps that build, run tests, deploy, and more: | ||
# https://aka.ms/yaml | ||
|
||
schedules: | ||
- cron: "0 8 * * *" | ||
displayName: Daily midnight build | ||
branches: | ||
include: | ||
- bluefield | ||
always: true | ||
|
||
trigger: none | ||
|
||
pr: | ||
branches: | ||
include: | ||
- bluefield | ||
paths: | ||
exclude: | ||
- .github | ||
|
||
name: $(TeamProject)_$(Build.DefinitionName)_$(SourceBranchName)_$(Date:yyyyMMdd)$(Rev:.r) | ||
|
||
resources: | ||
repositories: | ||
- repository: buildimage | ||
type: github | ||
name: nvidia-sonic/sonic-buildimage | ||
endpoint: nvidia-sonic | ||
ref: bluefield | ||
|
||
variables: | ||
- template: .azure-pipelines/azure-pipelines-repd-build-variables.yml@buildimage | ||
- template: .azure-pipelines/template-variables.yml@buildimage | ||
- name: CACHE_MODE | ||
value: rcache | ||
- name: ENABLE_FIPS | ||
value: y | ||
|
||
stages: | ||
- stage: Build | ||
dependsOn: [] | ||
jobs: | ||
- template: .azure-pipelines/azure-pipelines-build.yml | ||
parameters: | ||
buildOptions: 'USERNAME=admin SONIC_BUILD_JOBS=$(nproc) ${{ variables.VERSION_CONTROL_OPTIONS }}' | ||
preSteps: | ||
- task: InstallSSHKey@0 | ||
displayName: 'Install an SSH key' | ||
inputs: | ||
knownHostsEntry: '$(myHostsEntry)' | ||
sshPublicKey: '$(myPubKey)' | ||
sshKeySecureFile: 'id_rsa' | ||
jobGroups: | ||
- name: nvidia-bluefield | ||
pool: sonicbld-arm64 | ||
timeoutInMinutes: 2880 | ||
variables: | ||
PLATFORM_ARCH: arm64 | ||
|
||
|