reverting #47
This file contains hidden or 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
name: Build pi-gen image | |
# on: | |
# push: | |
# tags: | |
# - 'v*.*.*' | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
jobs: | |
pi-gen-aryaos: | |
runs-on: ubuntu-latest | |
env: | |
DISABLE_FIRST_BOOT_USER_RENAME: 1 | |
ENABLE_SSH: 1 | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
# add a step to copy the pi-gen/config file to pi-gen/.env: | |
# - name: Copy .env file | |
# run: cp pi-gen/config pi-gen/.env | |
# - name: Load .env file | |
# uses: xom9ikk/[email protected] | |
# with: | |
# path: pi-gen/ | |
# - name: Create shared_files directory | |
# run: cp -pr shared_files pi-gen/ | |
- name: Set current working directory | |
run: echo "GITHUB_CWD=$(pwd)" >> $GITHUB_ENV | |
- name: Set SHARED_FILES dir | |
run: echo "SHARED_FILES=$(pwd)/shared_files" >> $GITHUB_ENV | |
- name: Show env | |
run: env | |
# - name: Build RPi base OS image | |
# uses: usimd/pi-gen-action@v1 | |
# id: build_base | |
# # This is the first build step, it will create the base image. | |
# # The base image is the first stage of the pi-gen build process. | |
# # It will create a base image with the necessary files and directories. | |
# # The base image will be used as the starting point for the next stages. | |
# env: | |
# SHARED_FILES: ${{ env.SHARED_FILES }} | |
# GITHUB_CWD: ${{ env.GITHUB_CWD }} | |
# with: | |
# increase-runner-disk-size: true | |
# export-last-stage-only: false | |
# extra-host-dependencies: 'git' | |
# pi-gen-dir: pi-gen-src | |
# # Disable the renaming of the first user during the first boot. This make it so | |
# # 'username' stays activated. 'username' must be set for this to work. Please be | |
# # aware of the implied security risk of defining a default username and password | |
# # for your devices. | |
# disable-first-boot-user-rename: ${{ env.DISABLE_FIRST_BOOT_USER_RENAME || 1 }} | |
# # Enable SSH access to Pi. | |
# enable-ssh: ${{ env.ENABLE_SSH || 1 }} | |
# image-name: ${{ env.IMG_NAME || 'aryaos' }}-${{ github.GITHUB_REF_NAME || 'undef' }} | |
# hostname: ${{ env.TARGET_HOSTNAME || 'aryaos' }} | |
# locale: ${{ env.LOCALE_DEFAULT || 'en_US.UTF-8' }} | |
# password: ${{ env.FIRST_USER_PASS || 'aryaos415' }} | |
# pi-gen-release: ${{ env.PI_GEN_RELEASE || 'AryaOS' }} | |
# release: ${{ env.RELEASE || 'bookworm' }} | |
# # stage-list: "stage0 stage1 stage2 ${{ env.GITHUB_CWD }}/stages/stage-base" | |
# stage-list: "${{ env.GITHUB_CWD }}/stages/stage-patch stage0 stage1 stage2" | |
# wpa-country: ${{ env.WPA_COUNTRY || 'US' }} | |
# wpa-essid: ${{ env.WPA_ESSID || 'AryaOS-WiFi' }} | |
# wpa-password: ${{ env.WPA_PASSWORD || 'aryaos415' }} | |
# keyboard-layout: ${{ env.KEYBOARD_LAYOUT || 'English (US)' }} | |
# keyboard-keymap: ${{ env.KEYBOARD_KEYMAP || 'us' }} | |
# pi-gen-version: arm64 | |
# verbose-output: true | |
- name: Build RPi AryaOS image | |
uses: usimd/pi-gen-action@v1 | |
id: build_aryaos | |
# This is the second build step, it will create the AryaOS image. | |
# The AryaOS image is the second stage of the pi-gen build process. | |
# It will create an image with the necessary files and directories for AryaOS. | |
# The AryaOS image will be used as the final image for the Pi. | |
# It will use the base image created in the previous step. | |
# The base image will be used as the starting point for the next stages. | |
# This step will also copy the shared_files directory to the pi-gen directory. | |
env: | |
SHARED_FILES: ${{ env.SHARED_FILES }} | |
GITHUB_CWD: ${{ env.GITHUB_CWD }} | |
with: | |
increase-runner-disk-size: true | |
pi-gen-dir: pi-gen-src | |
# Disable the renaming of the first user during the first boot. This make it so | |
# 'username' stays activated. 'username' must be set for this to work. Please be | |
# aware of the implied security risk of defining a default username and password | |
# for your devices. | |
disable-first-boot-user-rename: ${{ env.DISABLE_FIRST_BOOT_USER_RENAME || 1 }} | |
# Enable SSH access to Pi. | |
enable-ssh: ${{ env.ENABLE_SSH || 1 }} | |
image-name: ${{ env.IMG_NAME || 'aryaos' }}-${{ github.GITHUB_REF_NAME || 'undef' }} | |
hostname: ${{ env.TARGET_HOSTNAME || 'aryaos' }} | |
locale: ${{ env.LOCALE_DEFAULT || 'en_US.UTF-8' }} | |
password: ${{ env.FIRST_USER_PASS || 'aryaos415' }} | |
pi-gen-release: ${{ env.PI_GEN_RELEASE || 'AryaOS' }} | |
release: ${{ env.RELEASE || 'bookworm' }} | |
stage-list: "${{ env.GITHUB_CWD }}/stages/stage-patch stage0 stage1 stage2 ${{ env.GITHUB_CWD }}/stages/stage-base" | |
wpa-country: ${{ env.WPA_COUNTRY || 'US' }} | |
wpa-essid: ${{ env.WPA_ESSID || 'AryaOS-WiFi' }} | |
wpa-password: ${{ env.WPA_PASSWORD || 'aryaos415' }} | |
keyboard-layout: ${{ env.KEYBOARD_LAYOUT || 'English (US)' }} | |
keyboard-keymap: ${{ env.KEYBOARD_KEYMAP || 'us' }} | |
pi-gen-version: arm64 | |
verbose-output: true | |
- name: list dir | |
run: | | |
ls -alR | |
- name: Upload Pi-Gen artifact. | |
uses: actions/upload-artifact@v4 | |
with: | |
name: pi-gen-stage2 | |
path: stage2.tar.gz | |
# ${{ steps.build_aryaos.outputs.image-path }} |