Browse code

Add support for arm64 images

This patch enables proper support for arm64 images by disabling VNC support
and adding several properties to the image in glance that are necessary to
boot correctly:
hw_cdrom_bus=virtio
hw_machine_type=virt
os_command_line='console=ttyAMA0'

Change-Id: I68c9a5e0e083af2f92875c3bdf70df750f6e4d8f

Clark Laughlin authored on 2015/04/08 01:31:47
Showing 2 changed files
... ...
@@ -287,6 +287,10 @@ function upload_image {
287 287
         img_property="--property hw_cdrom_bus=scsi"
288 288
     fi
289 289
 
290
+    if is_arch "aarch64"; then
291
+        img_property="--property hw_machine_type=virt --property hw_cdrom_bus=virtio --property os_command_line='console=ttyAMA0'"
292
+    fi
293
+
290 294
     if [ "$container_format" = "bare" ]; then
291 295
         if [ "$unpack" = "zcat" ]; then
292 296
             openstack --os-token $token --os-url $GLANCE_SERVICE_PROTOCOL://$GLANCE_HOSTPORT image create "$image_name" $img_property --public --container-format=$container_format --disk-format $disk_format < <(zcat --force "${image}")
... ...
@@ -54,6 +54,12 @@ function configure_nova_hypervisor {
54 54
         iniset $NOVA_CONF DEFAULT vnc_enabled "false"
55 55
     fi
56 56
 
57
+    # arm64-specific configuration
58
+    if is_arch "aarch64"; then
59
+        # arm64 architecture currently does not support graphical consoles.
60
+        iniset $NOVA_CONF DEFAULT vnc_enabled "false"
61
+    fi
62
+
57 63
     ENABLE_FILE_INJECTION=$(trueorfalse False ENABLE_FILE_INJECTION)
58 64
     if [[ "$ENABLE_FILE_INJECTION" = "True" ]] ; then
59 65
         # When libguestfs is available for file injection, enable using