-
Notifications
You must be signed in to change notification settings - Fork 2
55 lines (48 loc) · 1.68 KB
/
nvidia-l4t-base.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
name: nvidia-l4t-base
on:
push:
branches: [ main ]
paths:
- 'nvidia/l4t-base/**'
pull_request:
branches: [ main ]
paths:
- 'nvidia/l4t-base/**'
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
defaults:
run:
working-directory: nvidia/l4t-base
steps:
- uses: actions/checkout@v4
- name: Install QEMU static binaries
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to DockerHub
if: github.event_name != 'pull_request'
uses: docker/login-action@v3
with:
username: ${{ secrets.CONTAINER_REGISTRY_USERNAME }}
password: ${{ secrets.CONTAINER_REGISTRY_PASSWORD }}
- name: Build and push
uses: docker/bake-action@v4
with:
workdir: nvidia/l4t-base
push: ${{ github.event_name != 'pull_request' }}
- name: Get the image description
if: github.event_name != 'pull_request'
id: image_description
run: |
echo "image_description=$(docker buildx bake --print 2> /dev/null | jq -r '.target.nvidia-l4t-base-35-3-1.labels."org.opencontainers.image.description"')" >> $GITHUB_ENV
- name: Update Docker Hub Description
if: github.event_name != 'pull_request'
uses: peter-evans/dockerhub-description@v3
with:
username: ${{ secrets.CONTAINER_REGISTRY_USERNAME }}
password: ${{ secrets.CONTAINER_DESCRIPTION_PASSWORD }}
repository: boxcutter/nvidia-l4t-base
short-description: ${{ env.image_description }}
readme-filepath: nvidia/l4t-base/README.md