Add support for CI testing #4
Workflow file for this run
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
on: | ||
workflow_call: | ||
inputs: | ||
host-platform: | ||
type: string | ||
required: true | ||
target-device: | ||
type: string | ||
required: true | ||
build-mode: | ||
type: string | ||
required: true | ||
build-type: | ||
type: string | ||
required: true | ||
upload-enabled: | ||
type: boolean | ||
required: true | ||
python-version: | ||
type: string | ||
required: true | ||
jobs: | ||
build: | ||
if: ${{ github.repository_owner == 'nvidia' }} | ||
uses: | ||
./.github/workflows/gh-build.yml | ||
with: | ||
client-repo: ${{ github.event.repository.name }} | ||
target-device: ${{ inputs.target-device }} | ||
runs-on: ${{ (inputs.host-platform == 'linux-x64' && 'linux-amd64-cpu8') || (inputs.host-platform == 'linux-aarch64' && 'linux-arm64-cpu16') || (inputs.host-platform == 'mac' && 'macos-latest') }} | ||
build-type: ${{ inputs.build-type }} | ||
use-container: ${{ inputs.host-platform == 'linux-x64' || inputs.host-platform == 'linux-aarch64'}} | ||
host-platform: ${{ inputs.host-platform }} | ||
dependencies-file: "" | ||
build-mode: ${{ inputs.build-mode }} | ||
upload-enabled: ${{ inputs.upload-enabled }} | ||
python-version: ${{ inputs.python-version }} | ||
secrets: inherit | ||
test: | ||
if: ${{ github.repository_owner == 'nvidia' }} | ||
needs: | ||
- build | ||
uses: | ||
./.github/workflows/gh-test.yml | ||
with: | ||
client-repo: ${{ github.event.repository.name }} | ||
target-device: ${{ inputs.target-device }} | ||
test-options: ${{ inputs.build-type }} | ||
runs-on: ${{ (inputs.host-platform == 'linux-x64' && 'linux-amd64-gpu-v100-latest-1') || (inputs.host-platform == 'linux-aarch64' && 'linux-arm64-cpu16') || (inputs.host-platform == 'mac' && 'macos-latest') }} | ||
runner-has-gpu: ${{ inputs.host-platform == 'linux-x64' }} | ||
build-type: ${{ inputs.build-type }} | ||
host-platform: ${{ inputs.host-platform }} | ||
dependencies-file: "" | ||
build-mode: ${{ inputs.build-mode }} | ||
upload-enabled: ${{ inputs.upload-enabled }} | ||
python-version: ${{ inputs.python-version }} | ||
secrets: inherit | ||
test: | ||
if: ${{ github.repository_owner == 'nvidia' }} | ||
needs: | ||
- build | ||
uses: | ||
./.github/workflows/gh-test.yml | ||
with: | ||
client-repo: ${{ github.event.repository.name }} | ||
target-device: ${{ inputs.target-device }} | ||
test-options: ${{ inputs.build-type }} | ||
runs-on: ${{ (inputs.host-platform == 'linux-x64' && 'linux-amd64-gpu-v100-latest-1') || (inputs.host-platform == 'linux-aarch64' && 'linux-arm64-cpu16') || (inputs.host-platform == 'mac' && 'macos-latest') }} | ||
runner-has-gpu: ${{ inputs.host-platform == 'linux-x64' }} | ||
build-type: ${{ inputs.build-type }} | ||
host-platform: ${{ inputs.host-platform }} | ||
dependencies-file: "" | ||
build-mode: ${{ inputs.build-mode }} | ||
upload-enabled: ${{ inputs.upload-enabled }} | ||
secrets: inherit |