Skip to content

Commit

Permalink
Add support for Ubuntu 24.04
Browse files Browse the repository at this point in the history
Signed-off-by: Dominik Gedon <[email protected]>
  • Loading branch information
nodeg authored and Bischoff committed Sep 25, 2024
1 parent a34be89 commit 00d4f9b
Show file tree
Hide file tree
Showing 6 changed files with 53 additions and 2 deletions.
1 change: 1 addition & 0 deletions backend_modules/libvirt/base/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ locals {
sles12sp5o = "${var.use_mirror_images ? "http://${var.mirror}" : "http://download.suse.de"}/install/SLE-12-SP5-JeOS-GM/SLES12-SP5-JeOS.x86_64-12.5-OpenStack-Cloud-GM.qcow2"
ubuntu2004o = "${var.use_mirror_images ? "http://${var.mirror}" : "http://cloud-images.ubuntu.com"}/focal/current/focal-server-cloudimg-amd64.img"
ubuntu2204o = "${var.use_mirror_images ? "http://${var.mirror}" : "http://cloud-images.ubuntu.com"}/jammy/current/jammy-server-cloudimg-amd64.img"
ubuntu2404o = "${var.use_mirror_images ? "http://${var.mirror}" : "http://cloud-images.ubuntu.com"}/noble/current/noble-server-cloudimg-amd64.img"
debian11o = "${var.use_mirror_images ? "http://${var.mirror}" : "http://cloud.debian.org"}/images/cloud/bullseye/latest/debian-11-genericcloud-amd64.qcow2"
debian12o = "${var.use_mirror_images ? "http://${var.mirror}" : "http://cloud.debian.org"}/images/cloud/bookworm/latest/debian-12-genericcloud-amd64.qcow2"
opensuse155-ci-pro = "${var.use_mirror_images ? "http://${var.mirror}" : "http://download.opensuse.org"}/repositories/systemsmanagement:/sumaform:/images:/libvirt/images/opensuse155-ci-pr.x86_64.qcow2"
Expand Down
24 changes: 24 additions & 0 deletions backend_modules/libvirt/host/user_data.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -513,6 +513,30 @@ packages: ["venv-salt-minion", "avahi-daemon", "qemu-guest-agent"]
packages: ["salt-minion", "avahi-daemon", "qemu-guest-agent"]
%{ endif }
%{ endif }

%{ if image == "ubuntu2404o" }

apt:
sources:
tools_pool_repo:
source: deb http://${ use_mirror_images ? mirror : "download.opensuse.org"}/repositories/systemsmanagement:/Uyuni:/Stable:/Ubuntu2404-Uyuni-Client-Tools/xUbuntu_24.04/ /
key: |
runcmd:
# WORKAROUND: cloud-init in Ubuntu 24.04 does not take care of the following
- echo "PermitRootLogin yes" >> /etc/ssh/sshd_config
# WORKAROUND: disable IPv6 until we have it in Provo
- echo 'Acquire::ForceIPv4 "true";' > /etc/apt/apt.conf.d/99force-ipv4
- systemctl restart sshd
- systemctl start qemu-guest-agent

%{ if install_salt_bundle }
packages: ["venv-salt-minion", "avahi-daemon", "qemu-guest-agent"]
%{ else }
packages: ["salt-minion", "avahi-daemon", "qemu-guest-agent"]
%{ endif }
%{ endif } # end Ubuntu 24.04

%{ if image == "debian12o" }
apt:
sources:
Expand Down
2 changes: 2 additions & 0 deletions modules/controller/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,8 @@ module "controller" {
ubuntu2004_sshminion = length(var.ubuntu2004_sshminion_configuration["hostnames"]) > 0 ? var.ubuntu2004_sshminion_configuration["hostnames"][0] : null
ubuntu2204_minion = length(var.ubuntu2204_minion_configuration["hostnames"]) > 0 ? var.ubuntu2204_minion_configuration["hostnames"][0] : null
ubuntu2204_sshminion = length(var.ubuntu2204_sshminion_configuration["hostnames"]) > 0 ? var.ubuntu2204_sshminion_configuration["hostnames"][0] : null
ubuntu2404_minion = length(var.ubuntu2404_minion_configuration["hostnames"]) > 0 ? var.ubuntu2404_minion_configuration["hostnames"][0] : null
ubuntu2404_sshminion = length(var.ubuntu2404_sshminion_configuration["hostnames"]) > 0 ? var.ubuntu2404_sshminion_configuration["hostnames"][0] : null
debian11_minion = length(var.debian11_minion_configuration["hostnames"]) > 0 ? var.debian11_minion_configuration["hostnames"][0] : null
debian11_sshminion = length(var.debian11_sshminion_configuration["hostnames"]) > 0 ? var.debian11_sshminion_configuration["hostnames"][0] : null
debian12_minion = length(var.debian12_minion_configuration["hostnames"]) > 0 ? var.debian12_minion_configuration["hostnames"][0] : null
Expand Down
14 changes: 14 additions & 0 deletions modules/controller/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -506,6 +506,20 @@ variable "ubuntu2204_sshminion_configuration" {
}
}

variable "ubuntu2404_minion_configuration" {
description = "use module.<UBUNTU2404_MINION>.configuration, see main.tf.libvirt-testsuite.example"
default = {
hostnames = []
}
}

variable "ubuntu2404_sshminion_configuration" {
description = "use module.<UBUNTU2404_SSHMINION>.configuration, see main.tf.libvirt-testsuite.example"
default = {
hostnames = []
}
}

variable "debian11_minion_configuration" {
description = "use module.<DEBIAN11_MINION>.configuration, see main.tf.libvirt-testsuite.example"
default = {
Expand Down
4 changes: 2 additions & 2 deletions salt/controller/bashrc
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,8 @@ export VIRTHOST_KVM_PASSWORD="linux" {% else %}# no KVM host defined {% endif %}
{% if grains.get('rocky9_sshminion') | default(false, true) %}export ROCKY9_SSHMINION="{{ grains.get('rocky9_sshminion') }}" {% else %}# no ROCKY9 ssh minion defined {% endif %}
{% if grains.get('ubuntu2004_minion') | default(false, true) %}export UBUNTU2004_MINION="{{ grains.get('ubuntu2004_minion') }}" {% else %}# no UBUNTU2004 minion defined {% endif %}
{% if grains.get('ubuntu2004_sshminion') | default(false, true) %}export UBUNTU2004_SSHMINION="{{ grains.get('ubuntu2004_sshminion') }}" {% else %}# no UBUNTU2004 ssh minion defined {% endif %}
{% if grains.get('ubuntu2204_minion') | default(false, true) %}export UBUNTU2204_MINION="{{ grains.get('ubuntu2204_minion') }}" {% else %}# no UBUNTU2204 minion defined {% endif %}
{% if grains.get('ubuntu2204_sshminion') | default(false, true) %}export UBUNTU2204_SSHMINION="{{ grains.get('ubuntu2204_sshminion') }}" {% else %}# no UBUNTU2204 ssh minion defined {% endif %}
{% if grains.get('ubuntu2404_minion') | default(false, true) %}export UBUNTU2404_MINION="{{ grains.get('ubuntu2404_minion') }}" {% else %}# no UBUNTU2404 minion defined {% endif %}
{% if grains.get('ubuntu2404_sshminion') | default(false, true) %}export UBUNTU2404_SSHMINION="{{ grains.get('ubuntu2404_sshminion') }}" {% else %}# no UBUNTU2404 ssh minion defined {% endif %}
{% if grains.get('debian11_minion') | default(false, true) %}export DEBIAN11_MINION="{{ grains.get('debian11_minion') }}" {% else %}# no DEBIAN11 minion defined {% endif %}
{% if grains.get('debian11_sshminion') | default(false, true) %}export DEBIAN11_SSHMINION="{{ grains.get('debian11_sshminion') }}" {% else %}# no DEBIAN11 ssh minion defined {% endif %}
{% if grains.get('debian12_minion') | default(false, true) %}export DEBIAN12_MINION="{{ grains.get('debian12_minion') }}" {% else %}# no DEBIAN12 minion defined {% endif %}
Expand Down
10 changes: 10 additions & 0 deletions salt/mirror/etc/minima.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,7 @@ scc:
- RES8-Manager-Tools-Updates
- Ubuntu-20.04-SUSE-Manager-Tools
- Ubuntu-22.04-SUSE-Manager-Tools
- Ubuntu-24.04-SUSE-Manager-Tools
# SUSE Manager Beta Tools
- SLE-Manager-Tools12-Pool-Beta
- SLE-Manager-Tools12-Updates-Beta
Expand All @@ -155,6 +156,7 @@ scc:
- RES8-Manager-Tools-Updates-Beta
- Ubuntu-20.04-SUSE-Manager-Tools-Beta
- Ubuntu-22.04-SUSE-Manager-Tools-Beta
- Ubuntu-24.04-SUSE-Manager-Tools-Beta
archs: [x86_64, amd64]

http:
Expand Down Expand Up @@ -285,6 +287,10 @@ http:
- url: http://download.suse.de/ibs/Devel:/Galaxy:/Manager:/Head:/Ubuntu22.04-SUSE-Manager-Tools/xUbuntu_22.04
archs: [amd64]

# Ubuntu 24.04 Manager Tools Head devel
- url: http://download.suse.de/ibs/Devel:/Galaxy:/Manager:/Head:/Ubuntu24.04-SUSE-Manager-Tools/xUbuntu_24.04
archs: [amd64]

# openSUSE Leap
- url: http://download.opensuse.org/distribution/leap/15.2/repo/oss
archs: [x86_64]
Expand Down Expand Up @@ -367,6 +373,8 @@ http:
archs: [x86_64]
- url: http://download.opensuse.org/repositories/systemsmanagement:/Uyuni:/Master:/Ubuntu2204-Uyuni-Client-Tools/xUbuntu_22.04/
archs: [x86_64]
- url: http://download.opensuse.org/repositories/systemsmanagement:/Uyuni:/Master:/Ubuntu2404-Uyuni-Client-Tools/xUbuntu_24.04/
archs: [x86_64]
- url: http://download.opensuse.org/repositories/systemsmanagement:/Uyuni:/Master:/Debian11-Uyuni-Client-Tools/Debian_11/
archs: [x86_64]
- url: http://download.opensuse.org/repositories/systemsmanagement:/Uyuni:/Master:/Debian12-Uyuni-Client-Tools/Debian_12/
Expand Down Expand Up @@ -397,6 +405,8 @@ http:
archs: [x86_64]
- url: http://download.opensuse.org/repositories/systemsmanagement:/Uyuni:/Stable:/Ubuntu2204-Uyuni-Client-Tools/xUbuntu_22.04/
archs: [x86_64]
- url: http://download.opensuse.org/repositories/systemsmanagement:/Uyuni:/Stable:/Ubuntu2404-Uyuni-Client-Tools/xUbuntu_24.04/
archs: [x86_64]
- url: http://download.opensuse.org/repositories/systemsmanagement:/Uyuni:/Stable:/Debian11-Uyuni-Client-Tools/Debian_11/
archs: [x86_64]
- url: http://download.opensuse.org/repositories/systemsmanagement:/Uyuni:/Stable:/Debian12-Uyuni-Client-Tools/Debian_12/
Expand Down

0 comments on commit 00d4f9b

Please sign in to comment.