1 ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
2 : Copyright (c) 2017 Enea AB, Cavium and others.
4 : All rights reserved. This program and the accompanying materials
5 : are made available under the terms of the Apache License, Version 2.0
6 : which accompanies this distribution, and is available at
7 : http://www.apache.org/licenses/LICENSE-2.0
8 ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
9 From: Stanislaw Kardach <stanislaw.kardach@cavium.com>
10 Date: Wed, 24 Feb 2016 20:07:06 +0100
11 Subject: [PATCH] Make qemu-kvm architecture aware
14 deployment/puppet/openstack_tasks/manifests/roles/compute.pp | 9 +++++++--
15 1 file changed, 7 insertions(+), 2 deletions(-)
17 diff --git a/deployment/puppet/openstack_tasks/manifests/roles/compute.pp b/deployment/puppet/openstack_tasks/manifests/roles/compute.pp
18 index 3fcfb51..c53409c 100644
19 --- a/deployment/puppet/openstack_tasks/manifests/roles/compute.pp
20 +++ b/deployment/puppet/openstack_tasks/manifests/roles/compute.pp
21 @@ -167,9 +167,14 @@ class openstack_tasks::roles::compute {
24 # From legacy libvirt.pp
25 + # Guard against some exotic distros with their `uname -m`
26 + $arch = $::architecture ? {
27 + /(arm64|aarch64)/ => 'aarch64',
28 + default => 'x86_64',
30 exec { 'symlink-qemu-kvm':
31 - command => '/bin/ln -sf /usr/libexec/qemu-kvm /usr/bin/qemu-system-x86_64',
32 - creates => '/usr/bin/qemu-system-x86_64',
33 + command => "/bin/ln -sf /usr/libexec/qemu-kvm /usr/bin/qemu-system-${arch}",
34 + creates => "/usr/bin/qemu-system-${arch}",