From 44ac8dfae806add5cd01640d79e7e534e5d98ca9 Mon Sep 17 00:00:00 2001 From: Otto Liljalaakso Date: Oct 10 2022 05:58:28 +0000 Subject: Add Koji scratch build to GNU Hello tutorial Using only local actions, it is difficult to check if a package builds successfully for all Fedora architectures. Also, interacting with Koji is an essential skill for Fedora packagers. For these reasons, a step is added to the GNU Hello packaging tutorial where a Koji scratch build is performed. --- diff --git a/modules/ROOT/pages/Installing_Packager_Tools.adoc b/modules/ROOT/pages/Installing_Packager_Tools.adoc index ce45c15..26a0ef1 100644 --- a/modules/ROOT/pages/Installing_Packager_Tools.adoc +++ b/modules/ROOT/pages/Installing_Packager_Tools.adoc @@ -32,6 +32,7 @@ you need to configure your account to be a member of the `mock` group: $ sudo usermod -a -G mock ---- +[#kerberos_ticket] == Acquiring Kerberos ticket Koji uses Kerberos for authentication. diff --git a/modules/ROOT/pages/Packaging_Tutorial_GNU_Hello.adoc b/modules/ROOT/pages/Packaging_Tutorial_GNU_Hello.adoc index edafae6..18fa402 100644 --- a/modules/ROOT/pages/Packaging_Tutorial_GNU_Hello.adoc +++ b/modules/ROOT/pages/Packaging_Tutorial_GNU_Hello.adoc @@ -542,6 +542,59 @@ To clean up your system, undo the installation: $ sudo dnf -C -y history undo last ---- +== Building in Fedora infrastructure + +Even though the package is not part of Fedora distrubution yet, +a xref:Using_the_Koji_Build_System.adoc#scratch_builds[scratch build] can be performed +to ensure that the package builds successfully in Fedora's Koji build system, +and that it builds successfully for all architectures supported by Fedora. +Such build is started by passing a source rpm package to `fedpkg build --scratch`. + +Note that Koji uses Kerberos for authentication. +See xref:Installing_Packager_Tools.adoc#kerberos_ticket[Acquiring Kerberos Ticket] for details. + +[subs="attributes+"] +---- +$ fedpkg --release rawhide build --scratch --srpm results_hello/2.10/1.fc{MAJOROSVER}/hello-2.10-1.fc{MAJOROSVER}.src.rpm +Building hello-2.10-1.fc{MAJOROSVER}.src.rpm for f{MAJOROSVER}-candidate +Created task: 92465688 +Task info: https://koji.fedoraproject.org/koji/taskinfo?taskID=92465688 +Watching tasks (this may be safely interrupted)... +---- + +You can open the task info link in a browser to view build progress, logs and results. +The command line program also reports on progress as it happens. +Successful execution looks something like this: + +[subs="attributes+"] +---- +92465688 build (f{MAJOROSVER}-candidate, hello-2.10-1.fc{MAJOROSVER}.src.rpm): free +92465688 build (f{MAJOROSVER}-candidate, hello-2.10-1.fc{MAJOROSVER}.src.rpm): free -> open (buildvm-ppc64le-25.iad2.fedoraproject.org) + 92465698 rebuildSRPM (noarch): open (buildvm-s390x-24.s390.fedoraproject.org) + 92465745 buildArch (hello-2.10-1.fc{MAJOROSVER}.src.rpm, x86_64): free + 92465748 buildArch (hello-2.10-1.fc{MAJOROSVER}.src.rpm, s390x): open (buildvm-s390x-19.s390.fedoraproject.org) + 92465746 buildArch (hello-2.10-1.fc{MAJOROSVER}.src.rpm, aarch64): open (buildvm-a64-26.iad2.fedoraproject.org) + 92465747 buildArch (hello-2.10-1.fc{MAJOROSVER}.src.rpm, ppc64le): open (buildvm-ppc64le-11.iad2.fedoraproject.org) + 92465744 buildArch (hello-2.10-1.fc{MAJOROSVER}.src.rpm, i686): open (buildhw-x86-12.iad2.fedoraproject.org) + 92465698 rebuildSRPM (noarch): open (buildvm-s390x-24.s390.fedoraproject.org) -> closed + 1 free 5 open 1 done 0 failed + 92465745 buildArch (hello-2.10-1.fc{MAJOROSVER}.src.rpm, x86_64): free -> open (buildhw-x86-06.iad2.fedoraproject.org) + 92465745 buildArch (hello-2.10-1.fc{MAJOROSVER}.src.rpm, x86_64): open (buildhw-x86-06.iad2.fedoraproject.org) -> closed + 0 free 5 open 2 done 0 failed + 92465748 buildArch (hello-2.10-1.fc{MAJOROSVER}.src.rpm, s390x): open (buildvm-s390x-19.s390.fedoraproject.org) -> closed + 0 free 4 open 3 done 0 failed + 92465746 buildArch (hello-2.10-1.fc{MAJOROSVER}.src.rpm, aarch64): open (buildvm-a64-26.iad2.fedoraproject.org) -> closed + 0 free 3 open 4 done 0 failed + 92465744 buildArch (hello-2.10-1.fc{MAJOROSVER}.src.rpm, i686): open (buildhw-x86-12.iad2.fedoraproject.org) -> closed + 0 free 2 open 5 done 0 failed +92465688 build (f37-candidate, hello-2.10-1.fc{MAJOROSVER}.src.rpm): open (buildvm-ppc64le-25.iad2.fedoraproject.org) -> closed + 0 free 1 open 6 done 0 failed + 92465747 buildArch (hello-2.10-1.fc{MAJOROSVER}.src.rpm, ppc64le): open (buildvm-ppc64le-11.iad2.fedoraproject.org) -> closed + 0 free 0 open 7 done 0 failed + +92465688 build (f{MAJOROSVER}-candidate, hello-2.10-1.fc{MAJOROSVER}.src.rpm) completed successfully +---- + == References * https://rpm-software-management.github.io/rpm/manual/[RPM Reference Manual]