mirror of
https://github.com/saymrwulf/onnxruntime.git
synced 2026-05-25 22:26:24 +00:00
1. Remove some unused code and simplify tools/ci_build/github/linux/run_dockerbuild.sh. 2. Enable Nuget CUDA tests. The original design was we could leverage Directory.Build.props and let cmake generate the required properties(USE_CUDA/...) there. However, in nuget packaging pipeline we test the package on a different host that doesn't run cmake command and doesn't have the auto-generated Directory.Build.props file.
80 lines
3.1 KiB
YAML
80 lines
3.1 KiB
YAML
parameters:
|
|
AgentPool : 'Linux-CPU-2019'
|
|
JobName : 'Linux_CI_Dev'
|
|
SubmoduleCheckoutMode: ''
|
|
RunDockerBuildArgs: '-o ubuntu20.04 -d cpu -x "--build_wheel"'
|
|
DoNodejsPack: 'false'
|
|
DoNugetPack: 'false'
|
|
NuPackScript: ''
|
|
RunInjectedPipeline: 'false'
|
|
InjectedPipeline: ''
|
|
DockerImageTag: ''
|
|
BuildConfig: ''
|
|
ArtifactName: 'drop-linux'
|
|
TimeoutInMinutes: 120
|
|
# Controls whether unreleased onnx opsets are allowed. Default is set to 1
|
|
AllowReleasedOpsetOnly: '1'
|
|
# to inject strategy, you need to pass in the whole yaml structure -
|
|
# https://docs.microsoft.com/en-us/azure/devops/pipelines/yaml-schema?view=azure-devops&tabs=schema#strategies
|
|
# see example in orttraining-linux-gpu-ci-pipeline.yml
|
|
Strategy: ''
|
|
|
|
jobs:
|
|
- job: ${{ parameters.JobName }}
|
|
workspace:
|
|
clean: all
|
|
timeoutInMinutes: ${{ parameters.TimeoutInMinutes }}
|
|
variables:
|
|
ALLOW_RELEASED_ONNX_OPSET_ONLY: ${{ parameters.AllowReleasedOpsetOnly }}
|
|
pool: ${{ parameters.AgentPool }}
|
|
${{ if ne(parameters.Strategy, '') }}:
|
|
strategy:
|
|
${{ parameters.Strategy }}
|
|
steps:
|
|
- checkout: self
|
|
${{ if ne(parameters.SubmoduleCheckoutMode, '') }}:
|
|
submodules: ${{ parameters.SubmoduleCheckoutMode }}
|
|
- task: NodeTool@0
|
|
inputs:
|
|
versionSpec: '12.16.3'
|
|
- template: run-docker-build-steps.yml
|
|
parameters:
|
|
RunDockerBuildArgs: '${{ parameters.RunDockerBuildArgs }}'
|
|
- task: PublishTestResults@2
|
|
displayName: 'Publish unit test results'
|
|
inputs:
|
|
testResultsFiles: '**/*.results.xml'
|
|
searchFolder: '$(Build.BinariesDirectory)'
|
|
testRunTitle: 'Unit Test Run'
|
|
condition: succeededOrFailed()
|
|
- ${{ if eq(parameters['DoNugetPack'], 'true') }}:
|
|
- script: |
|
|
${{ parameters.NuPackScript }}
|
|
displayName: 'Create Artifacts'
|
|
- task: PublishPipelineArtifact@0
|
|
displayName: 'Publish Pipeline Artifact'
|
|
inputs:
|
|
artifactName: ${{ parameters.ArtifactName }}
|
|
targetPath: '$(Build.ArtifactStagingDirectory)'
|
|
- ${{ if eq(parameters['DoNodejsPack'], 'true') }}:
|
|
- script: |
|
|
npm pack
|
|
cp $(Build.SourcesDirectory)/js/node/onnxruntime-*.tgz $(Build.ArtifactStagingDirectory)
|
|
cp -R $(Build.SourcesDirectory)/js/node/prebuilds $(Build.ArtifactStagingDirectory)/prebuilds
|
|
workingDirectory: '$(Build.SourcesDirectory)/js/node'
|
|
displayName: 'Create NPM Package'
|
|
- task: PublishPipelineArtifact@0
|
|
displayName: 'Publish Pipeline Artifact: ${{ parameters.ArtifactName }}'
|
|
inputs:
|
|
artifactName: ${{ parameters.ArtifactName }}
|
|
targetPath: '$(Build.ArtifactStagingDirectory)'
|
|
- ${{ if eq(parameters['RunInjectedPipeline'], 'true') }}:
|
|
- template: |
|
|
${{ parameters.InjectedPipeline }}
|
|
parameters:
|
|
DockerImageTag: ${{ parameters.DockerImageTag }}
|
|
BuildConfig: ${{ parameters.BuildConfig }}
|
|
- template: component-governance-component-detection-steps.yml
|
|
parameters :
|
|
condition : 'succeeded'
|
|
- template: clean-agent-build-directory-step.yml
|