This commit is contained in:
parent
2a8a22c19d
commit
9b7a028614
1
.github/push-iso
vendored
Normal file
1
.github/push-iso
vendored
Normal file
@ -0,0 +1 @@
|
|||||||
|
1
|
37
.github/workflows/push-iso.yml
vendored
Normal file
37
.github/workflows/push-iso.yml
vendored
Normal file
@ -0,0 +1,37 @@
|
|||||||
|
name: Push ISO
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
|
paths:
|
||||||
|
- '.github/push-iso'
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
container:
|
||||||
|
image: ubuntu:latest
|
||||||
|
volumes:
|
||||||
|
- /proc:/proc
|
||||||
|
options: --privileged -it
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
|
||||||
|
- name: Install SSH key
|
||||||
|
uses: shimataro/ssh-key-action@v2
|
||||||
|
with:
|
||||||
|
key: ${{ secrets.SSH_KEY }}
|
||||||
|
name: id_rsa
|
||||||
|
known_hosts: ${{ secrets.KNOWN_HOSTS }}
|
||||||
|
if_key_exists: replace
|
||||||
|
|
||||||
|
- name: Update APT Cache
|
||||||
|
run: apt-get update -y
|
||||||
|
|
||||||
|
- name: Get ISO Build Dependencies
|
||||||
|
run: ./generate_roofs_from_docker.sh
|
||||||
|
|
||||||
|
- name: Generate Image ROOTFS from PikaOS Docker image
|
||||||
|
run: ./generate_roofs_from_docker.sh
|
31
generate_roofs_from_docker.sh
Executable file
31
generate_roofs_from_docker.sh
Executable file
@ -0,0 +1,31 @@
|
|||||||
|
#! /bin/bash
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
mkdir -p "./LIVE_BOOT/rootfs"
|
||||||
|
|
||||||
|
ROOTFS_PATH="./LIVE_BOOT/rootfs"
|
||||||
|
|
||||||
|
# Pull and mount docker image
|
||||||
|
|
||||||
|
podman pull ghcr.io/pikaos-linux/pikaos-base:canaryv3
|
||||||
|
|
||||||
|
podman image mount pikaos-linux/pikaos-base:canaryv3 > ./docker-merged-path
|
||||||
|
|
||||||
|
DOCKER_MERGED_PATH=$(cat ./docker-merged-path)
|
||||||
|
|
||||||
|
# Safely Copy merged path contents to rootfs
|
||||||
|
|
||||||
|
rsync -av $DOCKER_MERGED_PATH/* $ROOTFS_PATH/
|
||||||
|
|
||||||
|
# Clean up Docker specific things
|
||||||
|
|
||||||
|
rm -rfv $ROOTFS_PATH/etc/apt/preferences.d/*docker*
|
||||||
|
|
||||||
|
rm -rfv $ROOTFS_PATH/etc/dpkg/dpkg.cfg.d/*docker*
|
||||||
|
|
||||||
|
# Setup hostname
|
||||||
|
|
||||||
|
echo "pikaos" | tee "$ROOTFS_PATH/etc/hostname"
|
||||||
|
|
||||||
|
ls $ROOTFS_PATH/
|
19
get_iso_build_dep.sh
Executable file
19
get_iso_build_dep.sh
Executable file
@ -0,0 +1,19 @@
|
|||||||
|
#! /bin/bash
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
export DEBIAN_FRONTEND="noninteractive"
|
||||||
|
|
||||||
|
apt-get install -y --option Dpkg::Options::="--force-confnew" \
|
||||||
|
debootstrap \
|
||||||
|
squashfs-tools \
|
||||||
|
xorriso \
|
||||||
|
isolinux \
|
||||||
|
syslinux-efi \
|
||||||
|
grub-pc-bin \
|
||||||
|
grub-efi-amd64-bin \
|
||||||
|
grub-efi-ia32-bin \
|
||||||
|
mtools \
|
||||||
|
dosfstools \
|
||||||
|
rsync \
|
||||||
|
podman
|
Loading…
Reference in New Issue
Block a user