[lxc-devel] [lxc-ci/master] images/archlinux: Choose correct linux*.preset file

monstermunchkin on Github lxc-bot at linuxcontainers.org
Wed Mar 4 08:03:01 UTC 2020


A non-text attachment was scrubbed...
Name: not available
Type: text/x-mailbox
Size: 448 bytes
Desc: not available
URL: <http://lists.linuxcontainers.org/pipermail/lxc-devel/attachments/20200304/53abe13f/attachment.bin>
-------------- next part --------------
From 1be3ba8c37f3d9d56996f81a2c941d81cc650da4 Mon Sep 17 00:00:00 2001
From: Thomas Hipp <thomas.hipp at canonical.com>
Date: Wed, 4 Mar 2020 09:02:34 +0100
Subject: [PATCH] images/archlinux: Choose correct linux*.preset file

On ARM machines, the preset file is named linux-<arch>.preset instead of
linux.preset.

Signed-off-by: Thomas Hipp <thomas.hipp at canonical.com>
---
 images/archlinux.yaml | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/images/archlinux.yaml b/images/archlinux.yaml
index 6ed62e2..9c3cfe8 100644
--- a/images/archlinux.yaml
+++ b/images/archlinux.yaml
@@ -626,7 +626,12 @@ actions:
 
       # Rebuild initrd
       sed -i 's#^MODULES=.*#MODULES=(virtio_pci virtio_scsi virtio_console)#' /etc/mkinitcpio.conf
-      mkinitcpio -p linux
+
+      if [ "${TARGET}" = "x86_64" ]; then
+        mkinitcpio -p linux
+      else
+        mkinitcpio -p linux-$(uname -m)
+      fi
     types:
       - vm
 mappings:


More information about the lxc-devel mailing list