>From ea0142b9906ee5844f58b13b72eb6150ee020b6a Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Mon, 10 Oct 2022 13:54:52 +0100 Subject: [PATCH] customize: Support Rocky Linux Reported-by: Harry Benson Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=2133443 --- customize/hostname.ml | 3 ++- customize/password.ml | 3 ++- customize/random_seed.ml | 3 ++- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/customize/hostname.ml b/customize/hostname.ml index df64a2dab4..fabba3cfd7 100644 --- a/customize/hostname.ml +++ b/customize/hostname.ml @@ -36,7 +36,8 @@ let rec set_hostname (g : Guestfs.guestfs) root hostname = update_etc_machine_info g hostname; true - | "linux", ("rhel"|"centos"|"scientificlinux"|"oraclelinux"|"redhat-based"), v + | "linux", ("rhel"|"centos"|"scientificlinux"|"oraclelinux"|"rocky"| + "redhat-based"), v when v >= 7 -> update_etc_hostname g hostname; update_etc_machine_info g hostname; diff --git a/customize/password.ml b/customize/password.ml index 608bf95dcf..b37b31fcdc 100644 --- a/customize/password.ml +++ b/customize/password.ml @@ -160,7 +160,8 @@ and default_crypto g root = let distro = g#inspect_get_distro root in let major = g#inspect_get_major_version root in match distro, major with - | ("rhel"|"centos"|"scientificlinux"|"oraclelinux"|"redhat-based"), v when v >= 9 -> + | ("rhel"|"centos"|"scientificlinux"|"oraclelinux"|"rocky"| + "redhat-based"), v when v >= 9 -> `YESCRYPT | ("rhel"|"centos"|"scientificlinux"|"oraclelinux"|"redhat-based"), v when v >= 6 -> `SHA512 diff --git a/customize/random_seed.ml b/customize/random_seed.ml index f32d3194ea..2dcb700eaa 100644 --- a/customize/random_seed.ml +++ b/customize/random_seed.ml @@ -47,7 +47,8 @@ let rec set_random_seed (g : Guestfs.guestfs) root = let distro = g#inspect_get_distro root in let file = match typ, distro with - | "linux", ("fedora"|"rhel"|"centos"|"scientificlinux"|"oraclelinux"|"redhat-based") -> + | "linux", ("fedora"|"rhel"|"centos"|"scientificlinux"|"oraclelinux"| + "rocky"|"redhat-based") -> Some "/var/lib/random-seed" | "linux", ("debian"|"ubuntu"|"kalilinux") -> Some "/var/lib/urandom/random-seed" -- 2.37.0.rc2