Commit Graph

4339 Commits

Author SHA1 Message Date
Ian Wienand
7f98cfbcf7 bootloader: clean up EFI checking
The check removed here came in with
I4481b43e4a8fe4144be9c7eb9d9c618bbb2df21e a long time ago.  At that
time we were not building EFI images, and were building i386 images;
both of which are now untrue.

We can simplify this now by merging it into the gpt/mbr path.  If we
are in there we know that we should set --target=i386-pc for BIOS
boot.  For sanity check that we are x86 in this path -- PPC is handled
separately (although it's probably bit-rotted) and ARM64 is EFI.

Change-Id: Ie9839c9adc642b0dd688bced3faa46e9314e9799
Co-Authored-By: Clark Boylan <clark.boylan@gmail.com>
2022-02-22 11:03:14 +11:00
Clark Boylan
7d77f4fab2 Add rocky support to the epel element
OpenDev relies on the epel role to configure the epel repository for our
image builds. Specifically we need epel to pull in haveged. Update the
epel role to recognize rocky and configure it properly.

Change-Id: I968d4702ef39590e972b782a09e18a5db40703ad
2022-02-21 14:38:30 -08:00
Zuul
1ec7f1c238 Merge "Make growvols config path platform independent" 2022-02-21 19:33:11 +00:00
Zuul
2a9845ce46 Merge "update gpg / file verification for Gentoo" 2022-02-21 19:33:09 +00:00
Zuul
53524dec59 Merge "dhcp-all-interfaces: opt let NetworkManager doit." 2022-02-21 18:55:51 +00:00
Ian Wienand
0b48d74322 bootloader: fix arm64 install path
This fixes a regression introduced by
Ia99687815667c3cf5e82cf21d841d3b1008b8fa9

It turns out that [[ -d /usr/lib/grub/*-efi ]] is not a good check,
because [[ doesn't split that and try to glob match ( [ would ).  This
has resulted in us triggering this path on ARM64.

This is an x86-64 only check, because on other platforms we either
don't support EFI or are EFI only.  Restrict this check to get arm64
working again.

Change-Id: I6a75f8504826bcb0ac122d53dfb9faff975077f4
2022-02-21 13:41:47 +11:00
Matthew Thode
691eb03be8
update gpg / file verification for Gentoo
Gentoo updated the layout and files for vaidating stages
At least we can validate cryptographically and infer valid checksum now.

https://www.gentoo.org/news/2022/02/17/changed-signatures.html

Change-Id: I708b44419ae53dec2c19a2210ef427dcd2eb6002
Signed-off-by: Matthew Thode <mthode@mthode.org>
2022-02-18 14:17:00 -06:00
Clark Boylan
b3e81b19e7 Remove OS CI mirror role from fedora(-minimal) tests
The fedora and fedora-minimal elements currently test Fedora <=34. The
opendev ci mirrors no longer mirror Fedora 34 which means we cannot rely
on those mirrors for these tests. Remove the mirror configuration when
testing these older Fedora builds.

Change-Id: I817b412b7f06523df635e8b16111bc1081b40f66
2022-02-18 08:11:18 -08:00
Ian Wienand
f44644f20f Update platform support to describe stable testing
The reality is that "stable" is what is tested.  This tries to give
enough info that users can ascertain what tests are running at any
given time and hence what elements are known to be working.

Additional, clarify the Fedora position in the README as now described
by above.

Closes: #1653561
Change-Id: Ifb91b9089790897861bd7e671c3dba59adac239d
2022-02-16 10:40:09 +11:00
Zuul
354417f3e6 Merge "Fallback to persistent netifs names with systemd" 2022-02-14 21:30:06 +00:00
Ian Wienand
79ea63f525 Futher bootloader cleanups
GRUB_OPTS has never been documented as externally available, and is
not used.  Assume it's value to simplify the code.

Move the grub version check separately, as we only support grub2

Remove references to buliding i386 images.  I don't image it works in
any way.

Remove ci.md, which is no longer relevant.

Refactor the test for "building BIOS image on EFI system" consiberably
after these changes.

Change-Id: Ia99687815667c3cf5e82cf21d841d3b1008b8fa9
2022-02-10 15:08:56 +11:00
Zuul
b43c5967e8 Merge "fedora-container: pull in glibc-langpack-en" 2022-02-09 09:35:47 +00:00
Zuul
2332cceee7 Merge "Don't run functional tests on doc changes" 2022-02-09 09:21:06 +00:00
Riccardo Pittau
8401290976 Fallback to persistent netifs names with systemd
The dhcp-all-interfaces element does not work with the predictable names
scheme, fallback to the persistent names scheme as workaround.

Bug: 1960301

Change-Id: I117964a60615a5b7e9984f52f02cd018d1a48ed0
2022-02-09 10:17:49 +01:00
Zuul
b713c7fe6c Merge "Revert "Use rpm -e instead of dnf for cleaning old kernels"" 2022-02-09 07:50:24 +00:00
Zuul
f7c93fdca5 Merge "Remove extra if/then/else construct in pip element" 2022-02-09 05:19:36 +00:00
Zuul
2c159985a3 Merge "General improvements to the ubuntu-minimal docs" 2022-02-09 05:19:32 +00:00
Zuul
e9774d59bc Merge "Remove contrib/setup-gate-mirrors.sh" 2022-02-09 05:02:40 +00:00
Zuul
052a1df774 Merge "Cleanup more CentOS 8 bits" 2022-02-09 04:39:00 +00:00
Steve Baker
19ecc16d97 Revert "Use rpm -e instead of dnf for cleaning old kernels"
Using rpm -e to remove old kernels fails when other packages also
depend on the removed kernel.

This change reverts back to using dnf to remove the kernel, but also
sets the config value protect_running_kernel=False to avoid the issue
where the build host kernel version matches the version of the package
being deleted.

reverts commit 1ac31afd62.

Change-Id: Ie58630c23a34f2db34f3934abbd0c1076ab9d835
2022-02-09 03:33:34 +00:00
Zuul
2aa151b295 Merge "Add new container element - Rocky Linux" 2022-02-08 21:24:12 +00:00
Ian Wienand
2d36850877 fedora-container: pull in glibc-langpack-en
DevStack likes to use LC_ALL=en_US.UTF-8 because it does some
post-processing of output that depends on stable sort-order.  Pull in
the langpack package that provides this by default -- fedora-minimal
was doing this via yum-minimal so it makes sense to be equivalent.

Change-Id: I799bcfd73e1cb76ee1808b3441f40b0525e3c73d
2022-02-04 09:15:17 +11:00
Ramil Minishev
a27de3f8a2 Make growvols config path platform independent
Change-Id: I9b8fdf96c8543bff92019fb82f10493de7728a26
2022-02-04 00:23:13 +03:00
Zuul
256eeaba40 Merge "Add 9-stream ARM64 testing" 2022-02-01 07:44:31 +00:00
Zuul
4aa03bb5f0 Merge "Switch 9-stream testing to use opendev mirrors" 2022-02-01 07:43:54 +00:00
Zuul
3d905e772e Merge "centos: do not use $releasever in .repo files" 2022-02-01 07:43:51 +00:00
Ian Wienand
88d9ef21e8 Remove contrib/setup-gate-mirrors.sh
AFAICS, use of this was removed with
I7f98a13091056809fedae8a5c8ee10b0ef8bbb2a and I can't see any other
references to it.  Correct the comment to describe how it works.

Change-Id: I5123729b7457dcbd4f4a51cff49904f7bd071e9b
2022-02-01 15:44:01 +11:00
Ian Wienand
62101b6aa5 Cleanup more CentOS 8 bits
This removes some testing and mirror setup bits and pieces for CentOS
8 that is now EOL.

Change-Id: I18dec9054cf9e023bdf086bda3ba253b28d6540d
2022-02-01 15:39:24 +11:00
Ian Wienand
5aa552e22e Remove CentOS-8 jobs
In place with the upstream deprecation process [1] the upstream mirror
redirectors aren't returning links any more.  Eventually the repos
will move into vault/ probably.

At this point, we can't build centos-8, so remove the jobs.  There is
probably some more cleanup we can do, but this gets the gate going
again.

[1] https://www.centos.org/centos-linux-eol/

Depends-On: https://review.opendev.org/c/opendev/glean/+/827197
Change-Id: If819a035a9f3eae1e5546c1ccc6b23c4e2e91cb5
2022-02-01 11:04:45 +11:00
398e07e6f2 Add new container element - Rocky Linux
Introduce new container image for Rocky Linux, a downstream clone of Red
Hat Enterprise Linux.

Keep non-voting in Check for a while before adding to any gate checks

Signed-off-by: Neil Hanlon <neil@shrug.pw>
Change-Id: Ib383f60bc23b434b400f85c376840a000cafc697
Related-Bug: https://review.opendev.org/805800/
2022-01-31 17:26:16 +00:00
Zuul
fefd078dd2 Merge "Fix openSUSE images and bump them to 15.3" 2022-01-31 04:08:06 +00:00
Ian Wienand
7e2735846c Add 9-stream ARM64 testing
Change-Id: If8b139c295f80a4c241f18f02c83e1e9a2e21656
2022-01-28 18:53:20 +11:00
Ian Wienand
38449641bf Switch 9-stream testing to use opendev mirrors
Change-Id: Ib70726b1cd80fd47c9edaea7cc7a76c36883a3f2
2022-01-28 18:53:20 +11:00
Ian Wienand
d1b2a43a84 centos: do not use $releasever in .repo files
For centos stream, the $releasever is just the major version.  Several
of our .repo files are using $releasever in their path, and I think
that 8-stream installs are actually using 8 repos to install from.
For 9-stream, which doesn't have a corresponding 9, we're getting
errors enabling some of the aarch64 tests.

Replace all the $releasever expansions in the .repo files with the
exact version they are being installed for.  They don't need to be
generic; we are installing these specific repos for each DIB_RELEASE,
so they don't mix-and-match.

Change-Id: I48d438d8f51280cd060433fc8a67358d8345287f
2022-01-28 18:50:43 +11:00
Eduardo Santos
0f430664a2 Fix openSUSE images and bump them to 15.3
SUSE dropped OpenStack Cloud in 2019 [1], and as a result, some
OpenStack-related repositories were removed from openSUSE Download and
root filesystem images stopped being provided. This change deprecates
Leap releases before 15.3 and employs the extract-image script. It also
moves the extract-image script to the sysprep element, since now it's
also used by openSUSE-related elements.

Additionally, revert the "Remove opensuse related funtests" change [2]
so that the opensuse element is tested again and set the default Leap
release to 15.3.

[1] https://www.zdnet.com/article/suse-drops-openstacks/
[2] https://review.opendev.org/c/openstack/diskimage-builder/+/824002

Change-Id: I73d6323aa65cee69a55e54bc53ed682f096dfc89
2022-01-28 02:18:47 -03:00
Zuul
8690088ecd Merge "debian-minimal: remove old testing targets" 2022-01-27 23:53:26 +00:00
Zuul
6ca42f2a9d Merge "Add debian-bullseye-arm64 build test" 2022-01-27 23:49:09 +00:00
Ian Wienand
27feef8a26 debian-minimal: remove old testing targets
We've moved away from building "stable"/"testing" targets, as they
move over time so you never know what you're building.

These testing targets are unused, remove them to remove confusion.

Change-Id: I2a53f70ed07873b9a408972d2162b6c10b050db5
2022-01-25 15:54:39 +11:00
Ian Wienand
fa56c21109 Add debian-bullseye-arm64 build test
This does a basic vm build test of bullseye-arm64, which currently is
missing from the ARM64 testing.

To keep runtimes a bit more reasonable, split the job into two parts,
one for deb distros and one for rpm.

Change-Id: I0f28ff92e1b8d08d56b82b392e2cc355d567d007
2022-01-25 15:54:39 +11:00
Harald Jensås
e7c52139aa dhcp-all-interfaces: opt let NetworkManager doit.
NetworkManager is quite capable to do automatic
interface configuration. NetworkManager will by default
try to auto-configure any interface with no configuration.
It will use DHCP for IPv4 and Router Advertisements to
decide how to initialize IPv6.

It will most likely do it just as good, or better than the
dhcp-all-interfaces.sh script.

Since dhcp-all-interfaces clean out all ifcfg files in
60-remove-cloud-image-interfaces it means NetworkManager will
by default attempt auto configuration for all interfaces.

This change add's and environment variable:
  DIB_DHCP_NETWORK_MANAGER_AUTO (default: false)

When DIB_DHCP_NETWORK_MANAGER_AUTO is set to `true` only the
NetworkManager config will be written. The dhcp-all-interfaces
service will not be installed. Hence dhcp-all-interfaces will
not write any config files, allowing NetworkManager to just do
it's thing.

Change-Id: Id6f8d6aaaf52a78175bb6c065ec88274c364834e
2022-01-24 01:45:49 +01:00
Eduardo Santos
ca812ec5d7 Don't run functional tests on doc changes
Change-Id: I85f282c3d1ffa58f73f6c23871d970178fa1d586
2022-01-21 19:23:23 -03:00
Eduardo Santos
5779fa8525 General improvements to the ubuntu-minimal docs
This change:
- adds a note regarding an error when building focal ubuntu-minimal
  images on operating systems with older versions of debootstrap
- adds a reference to where the DIB_RELEASE variable definition can be
  found

Closes-Bug: #1941831
Change-Id: Ibc1e04dba0562c4f4909a8cb8af041d9b8ac45c4
2022-01-21 19:21:00 -03:00
Steve Baker
0d0f7f8075 Rename existing BLS entry with the new machine-id
This change replaces the call to grub2-switch-to-blscfg with a file
rename to update it to the actual machine-id.

grub2-switch-to-blscfg has issues in some build environments:
- When the build host is EFI boot, it assumes the image is, and
  fails when config file /etc/grub2-efi.cfg is missing
- With recent cento9 images and a fedora build host it fails with:
  grub2-probe: error: cannot find a device for / (is /dev mounted?)

Change-Id: I74ad800b702f2b491d958555cef8d7c7f63d74ac
2022-01-21 15:36:49 +13:00
Zuul
3df51c5279 Merge "Fixes for centos-9-stream efi behaviour" 2022-01-19 21:27:14 +00:00
Harald Jensås
9c5f5a56d4 Remove centos 9 and rhel 8 block in grub2 pkg-map
In the grub2 element the grub2-efi-x64-modules package
is missing in the centos 9 section, this cause a failure
because grub2 cannot find the neccecary files when
installing the bootloader on EFI systems.

It seems grub2-efi-x64-modules was not included in release
9, this is likely why the block was added initially without
this package. Since it is now there, the Centos 9 specific
block is no longer needed.

Removing the rhel 8 block as well, as it is identical to the
family "redhat" block i.e it is redundant.

Closes-Bug: #1957169
Change-Id: Ia6b0ecf0cd15fb23c6740543940ee513a8602afe
2022-01-17 23:40:24 +01:00
Steve Baker
a2cc17ad75 Fixes for centos-9-stream efi behaviour
This change removes the uninstall grub2-efi which was required for
prerelease rhel-9 images but now breaks current centos-9-stream
images. A different approach may be required for rhel-9 if the base
image remains different to centos-9-stream (such as populating the
empty /boot/efi partition from the base image)

This change also fixes the detection of whether this is an efi build
to check the block device instead of checking for whether a grub efi
package is installed. This fixes building a centos-9-stream whole-disk
image when package grub2-efi-x64 is installed but a legacy fallback
grub also needs to be installed.

Change-Id: I24baf553e1acd15a66737fc0b2a79d5335e28aa5
Partial-Bug: #1957789
2022-01-18 09:22:33 +13:00
Zuul
bef53f2674 Merge "enable cloud-init by default on systemd" 2022-01-14 19:47:41 +00:00
Steve Baker
9a7c107741 Use https for base centos image download
Change-Id: I85879ad784995405a1fa9fe8178e1b1d53d9e41a
2022-01-14 10:00:15 +13:00
Zuul
a32b969d95 Merge "Bump Ubuntu release to focal" 2022-01-11 11:21:13 +00:00
Zuul
83bbac0c2b Merge "centos: work around 9-stream BLS issues" 2022-01-11 09:38:35 +00:00