stackhpc / a-universe-from-nothing

Kayobe configuration for the Kayobe workshop "A Universe from Nothing: Containerised OpenStack deployment using Kolla, Ansible and Kayobe"
https://docs.openstack.org/kayobe/latest/
Apache License 2.0
79 stars 26 forks source link

Add support for running on Ubuntu #77

Closed markgoddard closed 3 years ago

markgoddard commented 3 years ago
markgoddard commented 3 years ago

Tested with the following changes:

--- a/a-universe-from-nothing.sh
+++ b/a-universe-from-nothing.sh
@@ -28,16 +28,38 @@ echo 'Defaults      !fqdn' | sudo tee /etc/sudoers.d/no-fqdn
 cd

 # Clone Kayobe.
-[[ -d kayobe ]] || git clone https://opendev.org/openstack/kayobe.git -b master
+[[ -d kayobe ]] || (git clone https://opendev.org/openstack/kayobe.git -b master &&
+cd kayobe &&
+git fetch "https://review.opendev.org/openstack/kayobe" refs/changes/98/780898/8 && git cherry-pick FETCH_HEAD &&
+git fetch "https://review.opendev.org/openstack/kayobe" refs/changes/20/781720/2 && git cherry-pick FETCH_HEAD &&
+git fetch "https://review.opendev.org/openstack/kayobe" refs/changes/75/777175/3 && git cherry-pick FETCH_HEAD &&
+git fetch "https://review.opendev.org/openstack/kayobe" refs/changes/76/777176/4 && git cherry-pick FETCH_HEAD &&
+git fetch "https://review.opendev.org/openstack/kayobe" refs/changes/00/776500/9 && git cherry-pick FETCH_HEAD &&
+sed -i -e '/- src: stackhpc.libvirt-host/d' requirements.yml &&
+sed -i -e '/  version: v1.7.1/d' requirements.yml &&
+cat<< EOF >> requirements.yml
+- src: https://github.com/stackhpc/ansible-role-libvirt-host
+  version: apparmor
+  name: stackhpc.libvirt-host
+EOF
+)
 cd kayobe

 # Clone the Tenks repository.
-[[ -d tenks ]] || git clone https://opendev.org/openstack/tenks.git
+[[ -d tenks ]] || (git clone https://opendev.org/openstack/tenks.git &&
+cd tenks &&
+sed -i -e '/- src: stackhpc.libvirt-host/d' requirements.yml &&
+cat<< EOF >> requirements.yml
+- src: https://github.com/stackhpc/ansible-role-libvirt-host
+  version: apparmor
+  name: stackhpc.libvirt-host
+EOF
+)

 # Clone this Kayobe configuration.
 mkdir -p config/src
 cd config/src/
-[[ -d kayobe-config ]] || git clone https://github.com/stackhpc/a-universe-from-nothing.git -b master kayobe-config
+[[ -d kayobe-config ]] || git clone https://github.com/stackhpc/a-universe-from-nothing.git -b ubuntu kayobe-config

 # Configure host networking (bridge, routes & firewall)
 ./kayobe-config/configure-local-networking.sh