mirror of
https://github.com/esphome/esphome.git
synced 2024-12-22 16:37:52 +01:00
c4a0015997
Co-authored-by: Jesse Hills <3060199+jesserockz@users.noreply.github.com>
54 lines
1.1 KiB
YAML
54 lines
1.1 KiB
YAML
name: CI for docker images
|
|
|
|
# Only run when docker paths change
|
|
on:
|
|
push:
|
|
branches: [dev, beta, release]
|
|
paths:
|
|
- 'docker/**'
|
|
- '.github/workflows/**'
|
|
- 'requirements*.txt'
|
|
- 'platformio.ini'
|
|
|
|
pull_request:
|
|
paths:
|
|
- 'docker/**'
|
|
- '.github/workflows/**'
|
|
- 'requirements*.txt'
|
|
- 'platformio.ini'
|
|
|
|
permissions:
|
|
contents: read
|
|
packages: read
|
|
|
|
jobs:
|
|
check-docker:
|
|
name: Build docker containers
|
|
runs-on: ubuntu-latest
|
|
strategy:
|
|
matrix:
|
|
arch: [amd64, armv7, aarch64]
|
|
build_type: ["ha-addon", "docker", "lint"]
|
|
steps:
|
|
- uses: actions/checkout@v3
|
|
- name: Set up Python
|
|
uses: actions/setup-python@v4
|
|
with:
|
|
python-version: '3.9'
|
|
- name: Set up Docker Buildx
|
|
uses: docker/setup-buildx-action@v2
|
|
- name: Set up QEMU
|
|
uses: docker/setup-qemu-action@v2
|
|
|
|
- name: Set TAG
|
|
run: |
|
|
echo "TAG=check" >> $GITHUB_ENV
|
|
|
|
- name: Run build
|
|
run: |
|
|
docker/build.py \
|
|
--tag "${TAG}" \
|
|
--arch "${{ matrix.arch }}" \
|
|
--build-type "${{ matrix.build_type }}" \
|
|
build
|