From 97e74314f5297d62252a9baca29e57bc30a3544f Mon Sep 17 00:00:00 2001 From: Ian Wienand Date: Tue, 30 Jan 2018 14:41:30 +1100 Subject: [PATCH] Add aarch64 configuration Add a valid aarch64 sources configuration file, and update the template to deploy the file on a per-architecture basis. Ensure we install the HWE kernel for arm64 servers Change-Id: If345e704540ea10828060d26e930a61ce68ed178 --- ...ist.precise => sources.list.precise.amd64} | 0 ....list.trusty => sources.list.trusty.amd64} | 0 .../files/sources.list.xenial.aarch64 | 35 +++++++++++++++++++ ....list.xenial => sources.list.xenial.amd64} | 0 modules/openstack_project/manifests/server.pp | 11 +++++- 5 files changed, 45 insertions(+), 1 deletion(-) rename modules/openstack_project/files/{sources.list.precise => sources.list.precise.amd64} (100%) rename modules/openstack_project/files/{sources.list.trusty => sources.list.trusty.amd64} (100%) create mode 100644 modules/openstack_project/files/sources.list.xenial.aarch64 rename modules/openstack_project/files/{sources.list.xenial => sources.list.xenial.amd64} (100%) diff --git a/modules/openstack_project/files/sources.list.precise b/modules/openstack_project/files/sources.list.precise.amd64 similarity index 100% rename from modules/openstack_project/files/sources.list.precise rename to modules/openstack_project/files/sources.list.precise.amd64 diff --git a/modules/openstack_project/files/sources.list.trusty b/modules/openstack_project/files/sources.list.trusty.amd64 similarity index 100% rename from modules/openstack_project/files/sources.list.trusty rename to modules/openstack_project/files/sources.list.trusty.amd64 diff --git a/modules/openstack_project/files/sources.list.xenial.aarch64 b/modules/openstack_project/files/sources.list.xenial.aarch64 new file mode 100644 index 0000000000..3c089f33f6 --- /dev/null +++ b/modules/openstack_project/files/sources.list.xenial.aarch64 @@ -0,0 +1,35 @@ +# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to +# newer versions of the distribution. + +deb http://ports.ubuntu.com/ubuntu-ports/ xenial main restricted multiverse +deb-src http://ports.ubuntu.com/ubuntu-ports/ xenial main restricted multiverse + +## Major bug fix updates produced after the final release of the +## distribution. +deb http://ports.ubuntu.com/ubuntu-ports/ xenial-updates main restricted multiverse +deb-src http://ports.ubuntu.com/ubuntu-ports/ xenial-updates main restricted multiverse + +## Uncomment the following two lines to add software from the 'universe' +## repository. +## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu +## team. Also, please note that software in universe WILL NOT receive any +## review or updates from the Ubuntu security team. +deb http://ports.ubuntu.com/ubuntu-ports/ xenial universe +deb-src http://ports.ubuntu.com/ubuntu-ports/ xenial universe +deb http://ports.ubuntu.com/ubuntu-ports/ xenial-updates universe +deb-src http://ports.ubuntu.com/ubuntu-ports/ xenial-updates universe + +## N.B. software from this repository may not have been tested as +## extensively as that contained in the main release, although it includes +## newer versions of some applications which may provide useful features. +## Also, please note that software in backports WILL NOT receive any review +## or updates from the Ubuntu security team. +# deb http://ports.ubuntu.com/ubuntu-ports/ xenial-backports main restricted +# deb-src http://ports.ubuntu.com/ubuntu-ports/ xenial-backports main restricted + +deb http://ports.ubuntu.com/ubuntu-ports/ xenial-security main restricted multiverse +deb-src http://ports.ubuntu.com/ubuntu-ports/ xenial-security main restricted multiverse +deb http://ports.ubuntu.com/ubuntu-ports/ xenial-security universe +deb-src http://ports.ubuntu.com/ubuntu-ports/ xenial-security universe +# deb http://ports.ubuntu.com/ubuntu-ports/ xenial-security multiverse +# deb-src http://ports.ubuntu.com/ubuntu-ports/ xenial-security multiverse \ No newline at end of file diff --git a/modules/openstack_project/files/sources.list.xenial b/modules/openstack_project/files/sources.list.xenial.amd64 similarity index 100% rename from modules/openstack_project/files/sources.list.xenial rename to modules/openstack_project/files/sources.list.xenial.amd64 diff --git a/modules/openstack_project/manifests/server.pp b/modules/openstack_project/manifests/server.pp index 55978c72a4..dfe753b466 100644 --- a/modules/openstack_project/manifests/server.pp +++ b/modules/openstack_project/manifests/server.pp @@ -103,7 +103,7 @@ class openstack_project::server ( group => 'root', mode => '0444', owner => 'root', - source => "puppet:///modules/openstack_project/sources.list.${::lsbdistcodename}", + source => "puppet:///modules/openstack_project/sources.list.${::lsbdistcodename}.${::architecture}", } exec { 'update-apt': command => 'apt-get update', @@ -340,4 +340,13 @@ class openstack_project::server ( ensure => file, require => File['/etc/cloud'], } + + if ($::lsbdistcodename == 'xenial' and $::architecture == 'aarch64') { + # Make sure we install the HWE kernel for arm64; it's 4.13 v 4.3 + # and works much better on linaro cloud + package { 'linux-generic-hwe-16.04': + ensure => present, + } + } + }