diff --git a/.github/workflows/build-iso.yml b/.github/workflows/build-iso.yml index 38aeaf5..f5ec7df 100644 --- a/.github/workflows/build-iso.yml +++ b/.github/workflows/build-iso.yml @@ -44,11 +44,11 @@ jobs: uses: actions/upload-artifact@v3 with: name: fedora-iso - path: ./_output/* + path: builddir/iso/* - name: Release uses: softprops/action-gh-release@v1 if: startsWith(github.ref, 'refs/tags/') with: files: | - _output/*.iso + builddir/iso/* diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..e2be6ae --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +builddir/ diff --git a/README.md b/README.md index 873d1f5..3e26c89 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,7 @@ # t2linux-fedora-iso A instalation ISO for Fedora on T2 macs. It uses the kernel patches from the [t2linux](https://t2linux.org) project. Read the [kernel README](https://github.com/t2linux/fedora-kernel/) for more information. Make sure to download the `.iso` or `.iso.0x` file. +Combine the split ISOs with `cat name_of_iso_here.iso.* > full.iso`. + ## Disclaimer This project is not officially provided or supported by the Fedora Project. The official Fedora software is available at [https://fedoraproject.org/](https://fedoraproject.org/). This project is not related to Fedora in any way. diff --git a/build.sh b/build.sh index 3a32e57..d65ceff 100755 --- a/build.sh +++ b/build.sh @@ -1,9 +1,31 @@ #!/usr/bin/bash +set -e -cd /repo/fedora-kickstarts -cp -rfv /repo/*.ks . -sudo ksflatten -c t2linux-fedora-workstation-live.ks -o flat.ks +kickstarts=( "fedora-live-workstation" "fedora-live-kde" ) -livemedia-creator --ks flat.ks --no-virt --resultdir /var/lmc --project Fedora-Workstation-Live-t2linux --make-iso --volid Fedora-WS-Live-t2-38-3.0.0 --iso-only --iso-name Fedora-Workstation-Live-t2linux-x86_64-38-3.0.0.iso --releasever 38 +mkdir -p /repo/builddir/iso +builddir=$(mktemp -d -p "/repo/builddir"); export builddir +function cleanup { + rm -rf "$builddir" +} +trap cleanup EXIT -mkdir -p _output && mv /var/lmc/*.iso _output/ +for ks in "${kickstarts[@]}"; do + ks_builddir="$builddir/$ks"; mkdir -p $ks_builddir; cd "$ks_builddir" + cp -r /repo/fedora-kickstarts/* .; cp -f /repo/*.ks . + echo '%include t2linux-fedora-common.ks' >> "$ks.ks" + sudo ksflatten --config "$ks.ks" --output "$ks-flat.ks" --version F39 + livemedia-creator \ + --make-iso \ + --iso-only \ + --no-virt \ + --resultdir results \ + --releasever 39 \ + --ks "$ks-flat.ks" \ + --project t2linux-Fedora-Live \ + --volid t2linux-Fedora-Live-39 \ + --iso-name "t2linux-$ks-39.iso" + find results/*.iso -size +2G -exec sh -c "split -b 1999M -x {} {}. && rm {}" \; + mv results/* /repo/builddir/iso/ +done +cleanup diff --git a/fedora-kickstarts b/fedora-kickstarts index 69c726f..465debb 160000 --- a/fedora-kickstarts +++ b/fedora-kickstarts @@ -1 +1 @@ -Subproject commit 69c726f7536cde6acf36697f7ba112ad3107e7ac +Subproject commit 465debb7c90c8ab4c68e14ff48fe50f796b1c089 diff --git a/t2linux-fedora-common.ks b/t2linux-fedora-common.ks index 17231e4..766009b 100644 --- a/t2linux-fedora-common.ks +++ b/t2linux-fedora-common.ks @@ -1,6 +1,6 @@ repo --name=tmp --cost=98 --baseurl=https://t2linux-fedora-repo.netlify.app/ -bootloader --append="intel_iommu=on iommu=pt pcie_ports=compat" +bootloader --append="intel_iommu=on iommu=pt" %packages diff --git a/t2linux-fedora-workstation-live.ks b/t2linux-fedora-workstation-live.ks deleted file mode 100644 index a2a28d8..0000000 --- a/t2linux-fedora-workstation-live.ks +++ /dev/null @@ -1,2 +0,0 @@ -%include t2linux-fedora-common.ks -%include fedora-live-workstation.ks