[PATCH 0/2] Misc: add a 'git-publish' profile; update Fedora versions
- On patch updates Fedora versions in the `virt-builder` man page - The other adds a 'git-publish' profile, similar to the one we've added for the main libguestfs repo: https://github.com/libguestfs/libguestfs/commit/8487e906d Kashyap Chamarthy (2): virt-builder.pod: Update Fedora versions Add a 'git-publish' profile .gitpublish | 3 ++ builder/virt-builder.pod | 72 ++++++++++++++++++++-------------------- 2 files changed, 39 insertions(+), 36 deletions(-) create mode 100644 .gitpublish -- 2.48.1
It's that time again. Update the Fedora versions in examples. For the index file example, I used Fedora 41 and 42 (which will come out in April 2025). Signed-off-by: Kashyap Chamarthy <kchamart@redhat.com> --- builder/virt-builder.pod | 72 ++++++++++++++++++++-------------------- 1 file changed, 36 insertions(+), 36 deletions(-) diff --git a/builder/virt-builder.pod b/builder/virt-builder.pod index aeb50529..05bef1e0 100644 --- a/builder/virt-builder.pod +++ b/builder/virt-builder.pod @@ -59,13 +59,13 @@ your own too (see below). After choosing a guest from the list, you may want to see if there are any installation notes: - virt-builder --notes fedora-27 + virt-builder --notes fedora-41 =head2 Build a virtual machine - virt-builder fedora-27 + virt-builder fedora-41 -will build a Fedora 25 image for the same architecture as virt-builder +will build a Fedora 41 image for the same architecture as virt-builder (so running it from an i686 installation will try to build an i686 image, if available). This will have all default configuration (minimal size, no user accounts, random root password, @@ -77,33 +77,33 @@ The first time this runs it has to download the template over the network, but this gets cached (see L</CACHING>). The name of the output file is derived from the template name, so -above it will be F<fedora-27.img>. You can change the output filename +above it will be F<fedora-41.img>. You can change the output filename using the I<-o> option: - virt-builder fedora-27 -o mydisk.img + virt-builder fedora-41 -o mydisk.img You can also use the I<-o> option to write to existing devices or logical volumes. - virt-builder fedora-27 --format qcow2 + virt-builder fedora-41 --format qcow2 -As above, but write the output in qcow2 format to F<fedora-27.qcow2>. +As above, but write the output in qcow2 format to F<fedora-41.qcow2>. - virt-builder fedora-27 --size 20G + virt-builder fedora-41 --size 20G As above, but the output size will be 20 GB. The guest OS is resized as it is copied to the output (automatically, using L<virt-resize(1)>). - virt-builder fedora-27 --arch i686 + virt-builder fedora-41 --arch i686 As above, but using an i686 template, if available. =head2 Setting the root password - virt-builder fedora-27 --root-password file:/tmp/rootpw + virt-builder fedora-41 --root-password file:/tmp/rootpw -Create a Fedora 25 image. The root password is taken from the file +Create a Fedora 41 image. The root password is taken from the file F</tmp/rootpw>. Note if you I<don’t> set I<--root-password> then the guest is given @@ -113,7 +113,7 @@ You can also create user accounts. See L</USERS AND PASSWORDS> below. =head2 Set the hostname - virt-builder fedora-27 --hostname virt.example.com + virt-builder fedora-41 --hostname virt.example.com Set the hostname to C<virt.example.com>. @@ -122,7 +122,7 @@ Set the hostname to C<virt.example.com>. To install packages from the ordinary (guest) software repository (eg. dnf or apt): - virt-builder fedora-27 --install "inkscape,@Xfce Desktop" + virt-builder fedora-41 --install "inkscape,@Xfce Desktop" (In Fedora, C<@> is used to install groups of packages. On Debian you would install a meta-package instead.) @@ -147,18 +147,18 @@ For example: dnf -y --best update EOF - virt-builder fedora-27 --firstboot /tmp/dnf-update.sh + virt-builder fedora-41 --firstboot /tmp/dnf-update.sh or simply: - virt-builder fedora-27 --firstboot-command 'dnf -y --best update' + virt-builder fedora-41 --firstboot-command 'dnf -y --best update' which makes the L<dnf(8)> C<update> command run once the first time the guest boots. Or: - virt-builder fedora-27 \ + virt-builder fedora-41 \ --edit '/etc/dnf/dnf.conf: s/gpgcheck=1/gpgcheck=0/' @@ -559,7 +559,7 @@ If the guest OS you are installing is similar to the host OS (eg. both are Linux), and if libguestfs supports network connections, then you can use I<--install> to install packages like this: - virt-builder fedora-27 --install inkscape + virt-builder fedora-41 --install inkscape This uses the guest’s package manager and the host’s network connection. @@ -568,7 +568,7 @@ connection. To update the installed packages in the template at build time: - virt-builder fedora-27 --update + virt-builder fedora-41 --update Most of the templates that ship with virt-builder come with a very minimal selection of packages (known as a "JEOS" or "Just Enough @@ -580,7 +580,7 @@ OS from the template. This option updates those template packages. Another option is to install the packages when the guest first boots: - virt-builder fedora-27 --firstboot-install inkscape + virt-builder fedora-41 --firstboot-install inkscape This uses the guest’s package manager and the guest’s network connection. @@ -628,7 +628,7 @@ For apt, create /tmp/install.sh containing: Use the I<--attach> option to attach the CD / disk image and the I<--run> option to run the script: - virt-builder fedora-27 \ + virt-builder fedora-41 \ --attach extra-packages.iso \ --run /tmp/install.sh @@ -707,7 +707,7 @@ keyboard for some common Linux distributions. For distros that use systemd C<localectl>, use a command like this: - virt-builder fedora-27 \ + virt-builder fedora-41 \ --firstboot-command 'localectl set-keymap uk' See L<localectl(1)> and @@ -749,9 +749,9 @@ of virt-builder to do this. This section contains examples for some common Linux distributions. -=head3 Setting Japanese in Fedora 25 +=head3 Setting Japanese in Fedora 41 - virt-builder fedora-27 \ + virt-builder fedora-41 \ --size 20G \ --update \ --install @japanese-support \ @@ -1014,7 +1014,7 @@ tools probably work differently as well. Import the image into Glance (the OpenStack image store) by doing: - glance image-create --name fedora-27-image --file fedora-27.img \ + glance image-create --name fedora-41-image --file fedora-41.img \ --disk-format raw --container-format bare \ --is-public True @@ -1024,12 +1024,12 @@ parameter should match virt-builder’s I<--format> option (or C<raw> if you didn't use that option). The I<--container-format> should always be C<bare> since virt-builder doesn't put images into containers. -You can use the S<C<glance image-show I<fedora-27-image>>> command to +You can use the S<C<glance image-show I<fedora-41-image>>> command to display the properties of the image. To boot up an instance of your image on a Nova compute node, do: - nova boot fedora-27-server --image fedora-27-image \ + nova boot fedora-41-server --image fedora-41-image \ --flavor m1.medium Use S<C<nova flavor-list>> to list possible machine flavors. Use @@ -1060,7 +1060,7 @@ at boot. A typical virt-builder command would be: - virt-builder fedora-27 \ + virt-builder fedora-41 \ --hostname client.example.com \ --update \ --install puppet \ @@ -1294,22 +1294,22 @@ options (see L<nbdkit-xz-plugin(1)> for further explanation): The index file has a simple text format (shown here without the digital signature): - [fedora-18] - name=Fedora® 18 - osinfo=fedora18 + [fedora-41] + name=Fedora® 41 + osinfo=fedora41 arch=x86_64 - file=fedora-18.xz + file=fedora-41.xz checksum[sha512]=... format=raw size=6442450944 compressed_size=148947524 expand=/dev/sda3 - [fedora-19] - name=Fedora® 19 - osinfo=fedora19 + [fedora-42] + name=Fedora® 42 + osinfo=fedora42 arch=x86_64 - file=fedora-19.xz + file=fedora-42.xz checksum[sha512]=... revision=3 format=raw @@ -1584,7 +1584,7 @@ package manager at that. To install a Fedora guest using a local mirror: - virt-builder fedora-27 \ + virt-builder fedora-41 \ --edit '/etc/yum.repos.d/fedora.repo: s{.*baseurl=.*}{baseurl=http://example.com/mirror/}; s{.*metalink=.*}{}; -- 2.48.1
The `git-publish`[1] tool is a wrapper around `git-format-patch` and `git-send-email`. It's a handy tool that automates some of the tedious aspects of patch submission. We've added it for the main libguestfs repo here[1]. [1] https://github.com/libguestfs/libguestfs/commit/8487e906d Signed-off-by: Kashyap Chamarthy <kchamart@redhat.com> --- .gitpublish | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 .gitpublish diff --git a/.gitpublish b/.gitpublish new file mode 100644 index 00000000..2aae0c09 --- /dev/null +++ b/.gitpublish @@ -0,0 +1,3 @@ +[gitpublishprofile "default"] +base = master +to = guestfs@lists.libguestfs.org -- 2.48.1
Thanks, both are now upstream in 5520f1cfae5..d91dd89508b Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com nbdkit - Flexible, fast NBD server with plugins https://gitlab.com/nbdkit/nbdkit
participants (2)
-
Kashyap Chamarthy -
Richard W.M. Jones