mirror of
https://github.com/meshtastic/firmware.git
synced 2025-02-01 18:29:56 +00:00
0fdbf70452
Some checks are pending
CI / setup (check) (push) Waiting to run
CI / setup (esp32) (push) Waiting to run
CI / setup (esp32c3) (push) Waiting to run
CI / setup (esp32c6) (push) Waiting to run
CI / setup (esp32s3) (push) Waiting to run
CI / setup (nrf52840) (push) Waiting to run
CI / setup (rp2040) (push) Waiting to run
CI / setup (stm32) (push) Waiting to run
CI / check (push) Blocked by required conditions
CI / build-esp32 (push) Blocked by required conditions
CI / build-esp32-s3 (push) Blocked by required conditions
CI / build-esp32-c3 (push) Blocked by required conditions
CI / build-esp32-c6 (push) Blocked by required conditions
CI / build-nrf52 (push) Blocked by required conditions
CI / build-rpi2040 (push) Blocked by required conditions
CI / build-stm32 (push) Blocked by required conditions
CI / package-raspbian (push) Waiting to run
CI / package-raspbian-armv7l (push) Waiting to run
CI / package-native (push) Waiting to run
CI / build-debian-src (push) Waiting to run
CI / test-native (push) Waiting to run
CI / docker-debian-amd64 (push) Waiting to run
CI / docker-alpine-amd64 (push) Waiting to run
CI / docker-debian-arm64 (push) Waiting to run
CI / docker-debian-armv7 (push) Waiting to run
CI / after-checks (push) Blocked by required conditions
CI / gather-artifacts (esp32) (push) Blocked by required conditions
CI / gather-artifacts (esp32c3) (push) Blocked by required conditions
CI / gather-artifacts (esp32c6) (push) Blocked by required conditions
CI / gather-artifacts (esp32s3) (push) Blocked by required conditions
CI / gather-artifacts (nrf52840) (push) Blocked by required conditions
CI / gather-artifacts (rp2040) (push) Blocked by required conditions
CI / gather-artifacts (stm32) (push) Blocked by required conditions
CI / release-artifacts (push) Blocked by required conditions
CI / release-firmware (esp32) (push) Blocked by required conditions
CI / release-firmware (esp32c3) (push) Blocked by required conditions
CI / release-firmware (esp32c6) (push) Blocked by required conditions
CI / release-firmware (esp32s3) (push) Blocked by required conditions
CI / release-firmware (nrf52840) (push) Blocked by required conditions
CI / release-firmware (rp2040) (push) Blocked by required conditions
CI / release-firmware (stm32) (push) Blocked by required conditions
Flawfinder Scan / Flawfinder (push) Waiting to run
74 lines
1.9 KiB
YAML
74 lines
1.9 KiB
YAML
name: Build Docker
|
|
|
|
# Build Docker image, push untagged (digest-only)
|
|
|
|
on:
|
|
workflow_call:
|
|
secrets:
|
|
DOCKER_FIRMWARE_TOKEN:
|
|
required: false # Only required for push
|
|
inputs:
|
|
distro:
|
|
description: Distro to target
|
|
required: true
|
|
type: string
|
|
# choices: [debian, alpine]
|
|
platform:
|
|
description: Platform to target
|
|
required: true
|
|
type: string
|
|
runs-on:
|
|
description: Runner to use
|
|
required: true
|
|
type: string
|
|
push:
|
|
description: Push images to registry
|
|
required: false
|
|
type: boolean
|
|
default: false
|
|
outputs:
|
|
digest:
|
|
description: Digest of built image
|
|
value: ${{ jobs.docker-build.outputs.digest }}
|
|
|
|
permissions:
|
|
contents: write
|
|
packages: write
|
|
|
|
jobs:
|
|
docker-build:
|
|
outputs:
|
|
digest: ${{ steps.docker_variant.outputs.digest }}
|
|
runs-on: ${{ inputs.runs-on }}
|
|
steps:
|
|
- name: Checkout code
|
|
uses: actions/checkout@v4
|
|
with:
|
|
submodules: recursive
|
|
ref: ${{github.event.pull_request.head.ref}}
|
|
repository: ${{github.event.pull_request.head.repo.full_name}}
|
|
|
|
- name: Docker login
|
|
if: ${{ inputs.push }}
|
|
uses: docker/login-action@v3
|
|
with:
|
|
username: meshtastic
|
|
password: ${{ secrets.DOCKER_FIRMWARE_TOKEN }}
|
|
|
|
- name: Set up QEMU
|
|
uses: docker/setup-qemu-action@v3
|
|
|
|
- name: Docker setup
|
|
uses: docker/setup-buildx-action@v3
|
|
|
|
- name: Docker build and push
|
|
uses: docker/build-push-action@v6
|
|
id: docker_variant
|
|
with:
|
|
context: .
|
|
file: |
|
|
${{ contains(inputs.distro, 'debian') && './Dockerfile' || contains(inputs.distro, 'alpine') && './alpine.Dockerfile' }}
|
|
push: ${{ inputs.push }}
|
|
tags: "" # Intentionally empty, push with digest only
|
|
platforms: ${{ inputs.platform }}
|