-
Notifications
You must be signed in to change notification settings - Fork 0
47 lines (42 loc) · 1.31 KB
/
usb-image.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
---
name: Build USB Sidecar
on: # yamllint disable-line rule:truthy
push:
branches:
- main
paths:
- .github/workflows/usb-image.yml
- images/usb-image/**
pull_request:
branches:
- main
paths:
- .github/workflows/usb-image.yml
- images/usb-image/**
jobs:
build-container:
env:
EARTHLY_TOKEN: ${{ secrets.EARTHLY_TOKEN }}
EARTHLY_ORG: marinatedconcrete
EARTHLY_SATELLITE: config-repo
runs-on: "ubuntu-latest"
permissions:
contents: "read"
packages: "write"
steps:
- uses: earthly/[email protected]
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
# renovate: datasource=docker depName=earthly/earthly
version: "v0.8.9"
- uses: "actions/[email protected]"
- name: "Login to GitHub Container Hub"
if: github.event_name != 'pull_request'
run: docker login --username "${{ github.actor }}" --password "${{ secrets.GITHUB_TOKEN }}" ghcr.io
- name: "Build USB Container Image"
run: earthly ./images/usb-image/+image
env:
EARTHLY_CI: true
EARTHLY_PUSH: ${{ github.event_name != 'pull_request' }}
# Only one platform per https://docs.earthly.dev/docs/earthly-command#build-options
EARTHLY_PLATFORMS: linux/amd64