Skip to content

Commit

Permalink
Merge branch 'master' into magic_bootargs
Browse files Browse the repository at this point in the history
  • Loading branch information
Itxaka authored Sep 20, 2023
2 parents 44f5782 + 52dd854 commit f8396f6
Show file tree
Hide file tree
Showing 21 changed files with 55 additions and 31 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/image.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ jobs:
# https://askubuntu.com/a/1081326
sudo setfacl -m u:runner:rwx /dev/kvm
- name: Install earthly
uses: jimmykarily/luet-install-action@v1.2
uses: Luet-lab/luet-install-action@v1.1
with:
repository: quay.io/kairos/packages
packages: utils/earthly
Expand Down
16 changes: 8 additions & 8 deletions .github/workflows/release-arm.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -105,15 +105,15 @@ jobs:
- name: Install Cosign
uses: sigstore/cosign-installer@main
- name: Install earthly
uses: jimmykarily/luet-install-action@v1.2
uses: Luet-lab/luet-install-action@v1.1
with:
repository: quay.io/kairos/packages
packages: utils/earthly
- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@master
- name: Login to DockerHub
uses: docker/login-action@v2
uses: docker/login-action@v3
with:
registry: quay.io
username: ${{ secrets.QUAY_USERNAME }}
Expand Down Expand Up @@ -221,15 +221,15 @@ jobs:
- name: Install Cosign
uses: sigstore/cosign-installer@main
- name: Install earthly
uses: jimmykarily/luet-install-action@v1.2
uses: Luet-lab/luet-install-action@v1.1
with:
repository: quay.io/kairos/packages
packages: utils/earthly
- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@master
- name: Login to DockerHub
uses: docker/login-action@v2
uses: docker/login-action@v3
with:
registry: quay.io
username: ${{ secrets.QUAY_USERNAME }}
Expand Down Expand Up @@ -293,7 +293,7 @@ jobs:
with:
fetch-depth: 0
- name: Install earthly
uses: jimmykarily/luet-install-action@v1.2
uses: Luet-lab/luet-install-action@v1.1
with:
repository: quay.io/kairos/packages
packages: utils/earthly
Expand All @@ -303,7 +303,7 @@ jobs:
platforms: all
- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v2
uses: docker/setup-buildx-action@v3
- name: Login to Quay Registry
run: echo ${{ secrets.QUAY_PASSWORD }} | docker login -u ${{ secrets.QUAY_USERNAME }} --password-stdin quay.io
- name: Build iso 🔧
Expand Down Expand Up @@ -333,7 +333,7 @@ jobs:
with:
fetch-depth: 0
- name: Install earthly
uses: jimmykarily/luet-install-action@v1.2
uses: Luet-lab/luet-install-action@v1.1
with:
repository: quay.io/kairos/packages
packages: utils/earthly
Expand All @@ -343,7 +343,7 @@ jobs:
platforms: all
- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v2
uses: docker/setup-buildx-action@v3
- name: Login to Quay Registry
run: echo ${{ secrets.QUAY_PASSWORD }} | docker login -u ${{ secrets.QUAY_USERNAME }} --password-stdin quay.io
- name: Build iso 🔧
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ jobs:
- name: Install Cosign
uses: sigstore/cosign-installer@main
- name: Install earthly
uses: jimmykarily/luet-install-action@v1.2
uses: Luet-lab/luet-install-action@v1.1
with:
repository: quay.io/kairos/packages
packages: utils/earthly
Expand Down Expand Up @@ -176,7 +176,7 @@ jobs:
- name: Login to Quay Registry
run: echo ${{ secrets.QUAY_PASSWORD }} | docker login -u ${{ secrets.QUAY_USERNAME }} --password-stdin quay.io
- name: Install earthly
uses: jimmykarily/luet-install-action@v1.2
uses: Luet-lab/luet-install-action@v1.1
with:
repository: quay.io/kairos/packages
packages: utils/earthly
Expand Down Expand Up @@ -238,7 +238,7 @@ jobs:
with:
fetch-depth: 0
- name: Install earthly
uses: jimmykarily/luet-install-action@v1.2
uses: Luet-lab/luet-install-action@v1.1
with:
repository: quay.io/kairos/packages
packages: utils/earthly
Expand Down Expand Up @@ -276,7 +276,7 @@ jobs:
sudo rm -rf /usr/local/lib/android # will release about 10 GB if you don't need Android
sudo rm -rf /usr/share/dotnet # will release about 20GB if you don't need .NET
- name: Install earthly
uses: jimmykarily/luet-install-action@v1.2
uses: Luet-lab/luet-install-action@v1.1
with:
repository: quay.io/kairos/packages
packages: utils/earthly
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/reusable-build-flavor.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ jobs:
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }}
run: echo ${{ secrets.QUAY_PASSWORD }} | docker login -u ${{ secrets.QUAY_USERNAME }} --password-stdin quay.io
- name: Install earthly
uses: jimmykarily/luet-install-action@v1.2
uses: Luet-lab/luet-install-action@v1.1
with:
repository: quay.io/kairos/packages
packages: utils/earthly
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/reusable-build-framework-flavor.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
- name: Login to Quay Registry
run: echo ${{ secrets.QUAY_PASSWORD }} | docker login -u ${{ secrets.QUAY_USERNAME }} --password-stdin quay.io
- name: Install earthly
uses: jimmykarily/luet-install-action@v1.2
uses: Luet-lab/luet-install-action@v1.1
with:
repository: quay.io/kairos/packages
packages: utils/earthly
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/reusable-build-provider.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ jobs:
- run: |
git fetch --prune --unshallow
- name: Install earthly
uses: jimmykarily/luet-install-action@v1.2
uses: Luet-lab/luet-install-action@v1.1
with:
repository: quay.io/kairos/packages
packages: utils/earthly
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/reusable-docker-arm-build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ jobs:
id: buildx
uses: docker/setup-buildx-action@master
- name: Install earthly
uses: jimmykarily/luet-install-action@v1.2
uses: Luet-lab/luet-install-action@v1.1
with:
repository: quay.io/kairos/packages
packages: utils/earthly
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/reusable-image-and-iso-arm-generic.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }}
- name: Install earthly
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }}
uses: jimmykarily/luet-install-action@v1.2
uses: Luet-lab/luet-install-action@v1.1
with:
repository: quay.io/kairos/packages
packages: utils/earthly
Expand All @@ -27,7 +27,7 @@ jobs:
- name: Set up Docker Buildx
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }}
id: buildx
uses: docker/setup-buildx-action@v2
uses: docker/setup-buildx-action@v3
- name: Login to Quay Registry
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }}
run: echo ${{ secrets.QUAY_PASSWORD }} | docker login -u ${{ secrets.QUAY_USERNAME }} --password-stdin quay.io
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/reusable-provider-tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ jobs:
# https://askubuntu.com/a/1081326
sudo setfacl -m u:runner:rwx /dev/kvm
- name: Install earthly
uses: jimmykarily/luet-install-action@v1.2
uses: Luet-lab/luet-install-action@v1.1
with:
repository: quay.io/kairos/packages
packages: utils/earthly
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ jobs:
# https://askubuntu.com/a/1081326
sudo setfacl -m u:runner:rwx /dev/kvm
- name: Install earthly
uses: jimmykarily/luet-install-action@v1.2
uses: Luet-lab/luet-install-action@v1.1
with:
repository: quay.io/kairos/packages
packages: utils/earthly
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/reusable-qemu-acceptance-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ jobs:
- name: Display structure of downloaded files
run: ls -las .
- name: Install earthly
uses: jimmykarily/luet-install-action@v1.2
uses: Luet-lab/luet-install-action@v1.1
with:
repository: quay.io/kairos/packages
packages: utils/earthly
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/reusable-qemu-bundles-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
- name: Display structure of downloaded files
run: ls -las .
- name: Install earthly
uses: jimmykarily/luet-install-action@v1.2
uses: Luet-lab/luet-install-action@v1.1
with:
repository: quay.io/kairos/packages
packages: utils/earthly
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/reusable-qemu-netboot-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ jobs:
- run: |
git fetch --prune --unshallow
- name: Install earthly
uses: jimmykarily/luet-install-action@v1.2
uses: Luet-lab/luet-install-action@v1.1
with:
repository: quay.io/kairos/packages
packages: utils/earthly
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/reusable-qemu-reset-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
- name: Display structure of downloaded files
run: ls -las .
- name: Install earthly
uses: jimmykarily/luet-install-action@v1.2
uses: Luet-lab/luet-install-action@v1.1
with:
repository: quay.io/kairos/packages
packages: utils/earthly
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/reusable-upgrade-latest-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ jobs:
- name: Display structure of downloaded files
run: ls -las .
- name: Install earthly
uses: jimmykarily/luet-install-action@v1.2
uses: Luet-lab/luet-install-action@v1.1
with:
repository: quay.io/kairos/packages
packages: utils/earthly
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/reusable-upgrade-with-cli-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ jobs:
sudo rm -rfv build || true
df -h
- name: Install earthly
uses: jimmykarily/luet-install-action@v1.2
uses: Luet-lab/luet-install-action@v1.1
with:
repository: quay.io/kairos/packages
packages: utils/earthly
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/reusable-zfs-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
- name: Display structure of downloaded files
run: ls -R
- name: Install earthly
uses: jimmykarily/luet-install-action@v1.2
uses: Luet-lab/luet-install-action@v1.1
with:
repository: quay.io/kairos/packages
packages: utils/earthly
Expand Down
23 changes: 22 additions & 1 deletion Earthfile
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ ARG OS_NAME=${OS_ID}-${VARIANT}-${FLAVOR}
# renovate: datasource=docker depName=quay.io/luet/base
ARG LUET_VERSION=0.35.0
# renovate: datasource=docker depName=aquasec/trivy
ARG TRIVY_VERSION=0.45.0
ARG TRIVY_VERSION=0.45.1
ARG COSIGN_SKIP=".*quay.io/kairos/.*"
# TODO: rename ISO_NAME to something like ARTIFACT_NAME because there are place where we use ISO_NAME to refer to the artifact name

Expand Down Expand Up @@ -637,6 +637,27 @@ iso:
SAVE ARTIFACT /build/$ISO_NAME.iso kairos.iso AS LOCAL build/$ISO_NAME.iso
SAVE ARTIFACT /build/$ISO_NAME.iso.sha256 kairos.iso.sha256 AS LOCAL build/$ISO_NAME.iso.sha256


iso-uki:
COPY +version/VERSION ./
ARG VERSION=$(cat VERSION)
ARG TARGETARCH
ARG ISO_NAME=${OS_ID}-${VARIANT}-${FLAVOR}-${TARGETARCH}-${MODEL}-${VERSION}
ARG OSBUILDER_IMAGE
FROM $OSBUILDER_IMAGE
WORKDIR /build
COPY +uki/uki.efi /build/uki.efi
RUN mkdir -p /build/efi
# TODO: Create the img size based ont eh actual efi size!
RUN dd if=/dev/zero of=/build/efi/efiboot.img bs=1G count=1
RUN mkfs.msdos -F 32 -n 'EFIBOOTISO' /build/efi/efiboot.img
RUN mmd -i /build/efi/efiboot.img ::EFI
RUN mmd -i /build/efi/efiboot.img ::EFI/BOOT
# TODO: TARGETARCH should change the output name to BOOTAA64.EFI in arm64!
RUN mcopy -i /build/efi/efiboot.img /build/uki.efi ::EFI/BOOT/BOOTX64.EFI
RUN xorriso -as mkisofs -V 'EFI_ISO_BOOT' -e efiboot.img -no-emul-boot -o /build/$ISO_NAME.iso /build/efi/
SAVE ARTIFACT /build/$ISO_NAME.iso kairos.iso AS LOCAL build/$ISO_NAME.iso

# This target builds an iso using a remote docker image as rootfs instead of building the whole rootfs
# This should be really fast as it uses an existing image. This requires a pushed image from the +image target
# defaults to use the $IMAGE name (so ttl.sh/core-opensuse-leap:latest)
Expand Down
3 changes: 3 additions & 0 deletions examples/byoi/ubuntu-fips/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -155,5 +155,8 @@ RUN rm -rf /boot/initramfs-*
# Fixup sudo perms
RUN chown root:root /usr/bin/sudo && chmod 4755 /usr/bin/sudo

# Symlink kernel HMAC
RUN kernel=$(ls /boot/vmlinuz-* | head -n1) && ln -sf ."${kernel#/boot/}".hmac /boot/.vmlinuz.hmac

# Clear cache
RUN rm -rf /var/cache/* && journalctl --vacuum-size=1K && rm /etc/machine-id && rm /var/lib/dbus/machine-id && rm /etc/hostname
2 changes: 1 addition & 1 deletion tests/assets/live-overlay.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@ install:
grub_options:
extra_cmdline: foobarzz
bundles:
- rootfs_path: /usr/local/lib/extensions/kubo
- rootfs_path: /var/lib/extensions/kubo
targets:
- container://${BUNDLE_IMAGE}
2 changes: 1 addition & 1 deletion tests/bundles_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ var _ = Describe("kairos bundles test", Label("bundles-test"), func() {
out, _ = vm.Sudo("cat /oem/90_custom.yaml")
result = result + fmt.Sprintf("90_custom.yaml:\n%s\n", out)

out, _ = vm.Sudo("cat /usr/local/lib/extensions/kubo/usr/lib/extension-release.d/extension-release.kubo")
out, _ = vm.Sudo("cat /var/lib/extensions/kubo/usr/lib/extension-release.d/extension-release.kubo")
result = result + fmt.Sprintf("extension-release.kubo:\n%s\n", out)

out, _ = vm.Sudo("systemd-sysext status")
Expand Down

0 comments on commit f8396f6

Please sign in to comment.