-
Notifications
You must be signed in to change notification settings - Fork 27
67 lines (58 loc) · 2.16 KB
/
nvidia-test.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
name: Nvidia Graphics Tests
on:
# Uncomment this trigger only during workflow development
# pull_request:
# branches: [ main ]
# Manual trigger
workflow_dispatch:
inputs:
run_id:
description: 'Run id number'
required: true
type: number
jobs:
test:
runs-on: [self-hosted, testflinger]
env:
TESTFLINGER_DIR: .github/workflows/testflinger
strategy:
fail-fast: true
matrix:
job-queue:
- 202007-28059
# - 202008-2816s7
# - 202112-29789
# noprovision node, for CI testing
# - 202302-31212
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Get the artifact
uses: dawidd6/action-download-artifact@v6
with:
run_id: ${{ inputs.run_id }}
name: docker_${{ inputs.run_id }}.snap
- name: Publish to Store
uses: snapcore/action-publish@v1
env:
SNAPCRAFT_STORE_CREDENTIALS: ${{ secrets.SNAPCRAFT_LOGIN }}
with:
snap: docker_${{ inputs.run_id }}.snap
release: latest/edge/runid-${{ inputs.run_id }}
- name: Create Testflinger job queue
run: |
export JOB_QUEUE="${{ matrix.job-queue }}"
export SNAP_CHANNEL="latest/edge/runid-${{ inputs.run_id }}"
envsubst '$JOB_QUEUE' \
< $TESTFLINGER_DIR/nvidia-job.yaml \
> $TESTFLINGER_DIR/nvidia-job.temp
envsubst '$SNAP_CHANNEL' \
< $TESTFLINGER_DIR/scripts/setup.sh \
> $TESTFLINGER_DIR/scripts/setup.temp
mv $TESTFLINGER_DIR/nvidia-job.temp $TESTFLINGER_DIR/nvidia-job.yaml
mv $TESTFLINGER_DIR/scripts/setup.temp $TESTFLINGER_DIR/scripts/setup.sh
- name: Submit Testflinger job
uses: canonical/testflinger/.github/actions/submit@main
with:
poll: true
job-path: ${{ env.TESTFLINGER_DIR }}/nvidia-job.yaml