-
Notifications
You must be signed in to change notification settings - Fork 0
50 lines (41 loc) · 1.45 KB
/
lab.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
# self hoste runner on lab machine that compiles repo with qemu + docker buildx and uploads binary to jetson nano via ssh because its on the same network
name: lab build
on:
push: #needed for testing on this branch
workflow_dispatch:
inputs:
environment:
description: 'Environment'
required: true
default: 'lab'
# runner labeled x64, or i can specify the name of the runner instead
jobs:
build:
runs-on: [X64]
steps:
- name: checkout repository
uses: actions/checkout@v4
- name: setup docker qemu
uses: docker/setup-qemu-action@v3
- name: setup docker buildx
uses: docker/setup-buildx-action@v3
- name: pull jetson nano ubuntu docker image
run: docker pull jmoreiraseame/jetson-nano-ubuntu:1.0
- name: build project
run: |
docker run --rm --platform linux/arm64 -v ${{ github.workspace }}:/repo -w /repo jmoreiraseame/jetson-nano-ubuntu:1.0 /bin/bash -c "
echo '/repo:' && \
ls -la /repo && \
mkdir /repo/xc/xctest/build && \
cd /repo/xc/xctest/build && \
cmake .. && \
make && \
mkdir /repo/bin && \
cp test /repo/bin/ && \
ldd test
"
- name: install sshpass
run: sudo apt-get install -y sshpass
- name: ssh to jetson and copy binary
run: |
sshpass -p "${{ secrets.JETSON_PASSWORD }}" scp -r bin/ team06@10.21.221.56:/home/team06/