Rust Demos built for Torizon #59
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Copyright © SixtyFPS GmbH <[email protected]> | |
# SPDX-License-Identifier: GPL-3.0-only OR LicenseRef-Slint-Royalty-free-2.0 OR LicenseRef-Slint-Software-3.0 | |
name: Rust Demos built for Torizon | |
on: | |
workflow_dispatch: | |
inputs: | |
push: | |
type: boolean | |
description: "Push the built images" | |
workflow_call: | |
inputs: | |
push: | |
type: boolean | |
description: "Push the built images" | |
jobs: | |
build_containers: | |
runs-on: ubuntu-22.04 | |
strategy: | |
matrix: | |
include: | |
# Disabled armhf, as armv7 seems to have vanished from https://hub.docker.com/r/torizon/wayland-base-vivante/tags | |
# - target: armhf | |
# image_arch: linux/arm/v7 | |
# rust_toolchain_arch: armv7-unknown-linux-gnueabihf | |
# base_image_suffix: "" | |
- target: arm64 | |
image_arch: linux/arm64 | |
rust_toolchain_arch: aarch64-unknown-linux-gnu | |
base_image_suffix: "" | |
# - target: armhf | |
# image_arch: linux/arm/v7 | |
# rust_toolchain_arch: armv7-unknown-linux-gnueabihf | |
# base_image_suffix: "-vivante" | |
- target: arm64 | |
image_arch: linux/arm64 | |
rust_toolchain_arch: aarch64-unknown-linux-gnu | |
base_image_suffix: "-vivante" | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: Login to GitHub Container Registry | |
uses: docker/login-action@v3 | |
with: | |
registry: ghcr.io | |
username: ${{ github.actor }} | |
password: ${{ secrets.CR_PAT }} | |
- name: Build and push | |
uses: docker/build-push-action@v6 | |
with: | |
context: . | |
file: ./docker/Dockerfile.torizon-demos | |
push: ${{ github.event.inputs.push || inputs.push }} | |
tags: ghcr.io/slint-ui/slint/torizon-demos-${{matrix.target}}${{matrix.base_image_suffix}}:latest | |
platforms: ${{matrix.image_arch}} | |
build-args: | | |
TOOLCHAIN_ARCH=${{matrix.target}} | |
IMAGE_ARCH=${{matrix.image_arch}} | |
RUST_TOOLCHAIN_ARCH=${{matrix.rust_toolchain_arch}} | |
BASE_NAME=wayland-base${{matrix.base_image_suffix}} | |
WEATHER_API_KEY=${{secrets.WEATHER_API_KEY}} |