Commit Graph

112 Commits

Author SHA1 Message Date
Debarshi Ray
d437e83604 Clarify that %golang_arches_future are meant for RHEL 10
Since the RHEL conditional was only targeting RHEL 9, it wasn't clear
whether it needed updating for RHEL 10.  So, it's better to say that
%golang_arches are for RHEL 9 and older, and %golang_arches_future are
for Fedora and RHEL 10 onwards.

This doesn't change any behaviour of the built artifacts, because the
build is only shared with RHEL 9 onwards.  Hence, a conditional checking
for RHEL 9 is the same as one checking for RHEL 9 and older.

There's no need to do a build just for this.
2023-11-09 17:15:39 +01:00
Debarshi Ray
12fabacd03 Silence 'rpminspect --tests=annocheck' and 'rpminspect --tests=runpath'
The DT_RPATH or DT_RUNPATH value of /run/host%{_libdir} that's present
in %{_bindir}/toolbox is intentional [1].

[1] Upstream commit 6063eb27b9893994
    https://github.com/containers/toolbox/commit/6063eb27b9893994
    https://github.com/containers/toolbox/issues/821
2023-11-09 12:05:46 +01:00
Debarshi Ray
b6101bf73f Drop github.com/coreos/toolbox compatibility from RHEL 10 onwards
Some limited compatibility with github.com/coreos/toolbox was added to
RHEL 8.5 when the implementation of the toolbox RPM was changed from
github.com/coreos/toolbox to github.com/containers/toolbox.  This was
carried forward to RHEL 9 to give everybody some extra time to adjust.

This compatibility involved setting the HOST environment variable inside
the Toolbx containers for 'sos report' to work, and replicating the
command line interface from github.com/coreos/toolbox.

The problem with setting the HOST environment variable in Toolbx
containers is that it's a very generic name without any namespacing.
Not every user is going to use 'sos report', and it can easily conflict
with a variable of the same name being used for a different purpose.
This is similar to the NAME and VERSION environment variables that used
to be set inside Toolbx containers due to outdated or wrong information
in Fedora's container guidelines [1].  They were a constant source of
complaints and were recently fixed [2].  The same logic applies to HOST.

Instead of expecting the Toolbx container to have the HOST environment
variable, sos(1) should be taught how to work inside a Toolbx container
without requiring any extra configuration [3].

The problem with replicating the command line interface from
github.com/coreos/toolbox is that it's difficult to document it, because
it's so different from the native interface that users on non-RHEL
operating systems, including Fedora, have come to expect.  So, it's an
undocumented easter egg that receives very limited, if any, testing.

RHEL 8.5 was released on the 9th of November in 2021, which was almost
two years ago.  RHEL 10 is going to be a fresh new operating system.
It's time to ship a version of sos(1) in RHEL that works without any
extra configuration inside Toolbx containers, and to inform RHEL users
to adapt to the native command line interface.

[1] https://docs.fedoraproject.org/en-US/containers/guidelines/creation/

[2] Upstream commit 9506173f88dc26bf
    https://github.com/containers/toolbox/commit/9506173f88dc26bf
    https://github.com/containers/toolbox/issues/188

[3] https://github.com/sosreport/sos/pull/3370
2023-10-02 16:59:24 +02:00
Debarshi Ray
a8e2dd8823 Add two upstream patches that are already in CentOS Stream 9 2023-10-02 13:46:15 +02:00
Debarshi Ray
c91cdf0ad7 Unify the build with RHEL
This pulls in an extra patch [1] that's necessary to fix the build on
only CentOS Stream 9, not Fedora.  While not needed, it also doesn't
hurt Fedora and has the added benefit of keeping the build unified with
RHEL.

There's no need to do a build just for this.

[1] Upstream commit f555029304415a06
    https://github.com/containers/toolbox/commit/f555029304415a06
    https://github.com/containers/toolbox/issues/1246
2023-10-02 13:38:10 +02:00
Fedora Release Engineering
0ad2c75c04 Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2023-07-22 16:34:45 +00:00
Debarshi Ray
1591f98256 Remove trailing whitespace
There's no need to do a build just for this.

Fallout from a8db8e5d51
2023-06-26 15:29:46 +02:00
Debarshi Ray
b18f520f26 Pull in the rest of the RHEL specific patches to further unify the build
There's no need to do a build just for this.
2023-06-26 15:27:07 +02:00
Yaakov Selkowitz
006d4f5d81 Add missing files for RHEL builds
Source and Patch listings should not be conditionalized, as that causes
SRPM contents to be inconsistent.

https://src.fedoraproject.org/rpms/toolbox/pull-request/14
2023-06-26 15:08:36 +02:00
Debarshi Ray
037ea0e724 Don't 'BuildRequires: pkgconfig(fish)' on RHEL
... because RHEL doesn't have fish.

There's no need to do a build just for this.
2023-04-04 00:34:08 +02:00
Debarshi Ray
ef153bba41 Shuffle the BuildRequires around
There's no need to do a build just for this.
2023-04-04 00:27:52 +02:00
Debarshi Ray
7ddc864959 Update the commit messages of the downstream patches
Fedora now has a %{gobuildflags} RPM macro with only the flags used by
'go build ...'.

There's no need to do a build just for this.
2023-04-03 23:15:51 +02:00
Debarshi Ray
2f6e2b7cfe Unify the build with RHEL
There's no need to do a build just for this.
2023-04-03 22:23:50 +02:00
Debarshi Ray
a8b4975b5c Don't 'Requires: flatpak-session-helper' on RHEL
... because RHEL has always shipped toolbox >= 0.0.97 and hence doesn't
require flatpak-session-helper.

There's no need to do a build just for this.
2023-04-03 21:33:58 +02:00
Debarshi Ray
2f07af48f5 Don't 'Requires: bats' on RHEL
... because RHEL doesn't have bats.

There's no need to do a build just for this.
2023-04-03 21:33:53 +02:00
Nieves Montero
a8db8e5d51 Sprinkle a debug log
Signed-off-by: Nieves Montero <nmontero@redhat.com>
2023-03-08 11:24:16 +01:00
Debarshi Ray
2f7d549494 Don't use podman(1) when generating the completions
This is actually needed for Fedoras 36 and 37, but, at least currently,
not necessary for Fedoras 38 and 39.

There's no need to do a build just for this.

https://github.com/containers/podman/issues/17657
2023-02-28 19:38:33 +01:00
Debarshi Ray
95d6ea8689 Update to 0.0.99.4
https://bugzilla.redhat.com/show_bug.cgi?id=2171961
2023-02-23 18:05:26 +01:00
Debarshi Ray
79167d70c4 Remove a patch specific to Fedora that doesn't seem necessary anymore
There's no need to do a build just for this.
2023-02-23 17:49:22 +01:00
Debarshi Ray
cbcdb7a21c Simplify and unify the build with RHEL
There's no need to do a build just for this.
2023-02-23 16:13:42 +01:00
Debarshi Ray
7556bb66c2 Bump the golang requirement to ensure recent CVE fixes
'BuildRequires: golang >= 1.19.4' will ensure that recent CVEs like
CVE-2022-41717 remain fixed.

There's no need to do a build just for this, because the toolbox package
has either already been built with a sufficiently recent golang or will
soon be.

https://bugzilla.redhat.com/show_bug.cgi?id=2161274
2023-02-22 20:44:23 +01:00
Martin Jackson
fbfe9ff31b Fix the ExclusiveArch
The %gometa RPM macro also generates a ExclusiveArch on %golang_arches
or %golang_arches_future depending on whether the -f flag is present or
not.  This was overriding the separately specified ExclusiveArch.

Fallout from 7ce081c75c

https://src.fedoraproject.org/rpms/toolbox/pull-request/12
2023-02-22 19:22:47 +01:00
Debarshi Ray
7ce081c75c Add ExclusiveArch to match Podman
There's no golang on %ix86 from RHEL 9 onwards [1], and hence no podman
either [2].

Recently, with Podman 4.4.1, there are also no new podman builds for
%ix86 for Fedora 36 onwards [3].  Arguably, the podman change should
have been limited to Fedora Rawhide, but it's probably not a big problem
because there's no %ix86 install media for Fedora CoreOS, Silverblue or
Workstation.

Note that while %golang_arches on RHEL 9 doesn't include %arm, it's
included in both %golang_arches and %golang_arches_future on Fedora.

[1] go-rpm-macros commit b1500ff47ee8cdd1
    https://src.fedoraproject.org/rpms/go-rpm-macros/c/b1500ff47ee8cdd1

[2] podman commit 555a5a504dd538d5
    https://src.fedoraproject.org/rpms/podman/c/555a5a504dd538d5

[3] podman commit 313c3e86a81c69eb
    https://src.fedoraproject.org/rpms/podman/c/313c3e86a81c69eb
2023-02-21 18:22:41 +01:00
Debarshi Ray
5e28822115 Use %gomodulesmode introduced in go-rpm-macros-3.0.10
There's no need to do a build just for this.
2023-02-21 17:16:07 +01:00
Debarshi Ray
ecc081de3e Mark and comment out the unused BuildRequires for %check
Fallout from 484d3d6209 and
12df1ef16a

There's no need to do a build just for this.
2023-02-21 17:09:13 +01:00
Debarshi Ray
df688dd65b Add missing 'BuildRequires: gcc'
A C compiler is necessary to build Toolbx [1].  GCC is being pulled in
by the other BuildRequires, but it's good to explicitly list it since
GCC isn't part of the default buildroot since Fedora 29 [2] and will
prevent the compiler from unexpectedly changing to Clang.

There's no need to do a build just for this.

[1] Upstream commit c8aaed52c547e24e
    https://github.com/containers/toolbox/commit/c8aaed52c547e24e
    https://github.com/containers/toolbox/pull/923

[2] https://fedoraproject.org/wiki/Changes/Remove_GCC_from_BuildRoot
2023-02-21 17:06:29 +01:00
Debarshi Ray
021ab3822e Drop redundant option from %meson
There's no need to pass the --buildtype=plain option to the %meson RPM
macro, because it's one of the default options used by the macro.

There's no need to do a build just for this.

Fallout from 33bd39b0f9
2023-02-21 16:56:46 +01:00
Yaakov Selkowitz
484d3d6209 Sync packaging changes from CentOS Stream 2023-02-02 12:55:51 -05:00
Fedora Release Engineering
1815f6417e Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2023-01-21 05:16:24 +00:00
Yaakov Selkowitz
46d2ca508e Use vendored dependencies for RHEL 2022-12-22 16:17:31 -05:00
Fedora Release Engineering
9dc23837ed Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2022-07-23 10:41:32 +00:00
Maxwell G
f6c0926811
Rebuild for CVE-2022-{1705,32148,30631,30633,28131,30635,30632,30630,1962} in golang 2022-07-19 13:59:13 -05:00
Robert-André Mauchin
c2a3244ca4 Rebuilt for CVE-2022-1996, CVE-2022-24675, CVE-2022-28327, CVE-2022-27191, CVE-2022-29526, CVE-2022-30629 2022-06-18 12:23:53 +02:00
Debarshi Ray
b3f0d3b599 Add 'BuildRequires: golang(golang.org/x/crypto/ssh/terminal)'
Not having golang.org/x/crypto/ssh/terminal explicitly listed as a
BuildRequires isn't breaking the build at the moment.  However, since
it's a direct dependency, and Toolbx is written in Go, it's good to
explicitly list it due to the statically linked nature of Go binaries.
It will make it easier to gauge the fallout from a security bug.

There's no need to do a build just for this.
2022-05-18 00:07:18 +02:00
Debarshi Ray
da55cfac4e Add 'BuildRequires: golang(github.com/spf13/viper)'
Earlier Viper was being pulled in by Cobra, and hence wasn't explicitly
listed as a BuildRequires.  However, Cobra 1.4.0 removed the Viper
dependency [1], so it needs to be explicitly listed.

There's no need to do a build just for this.

[1] Cobra commit 5b2b9e9f61d36ccb
    https://github.com/spf13/cobra/issues/1597
2022-05-17 23:29:44 +02:00
Debarshi Ray
0329ca33cc Revert back to referring to go-md2man as go-md2man
The 'go-md2man' virtual Provides was briefly lost after the
golang-github-cpuguy83-go-md2man package was renamed to
golang-github-cpuguy83-md2man.  The virtual Provides has since been
restored [1], and go-md2man is being used as a standalone binary tool,
not as a Go package that's imported into Toolbx's source code.  Hence,
it makes sense to refer to the tool as go-md2man, and not by it's
import path.

This reverts commit 701836afca.

There's no need to do a build just for this.

[1] golang-github-cpuguy83-md2man commit c085b15e5acd8d07
    https://src.fedoraproject.org/rpms/golang-github-cpuguy83-md2man/c/c085b15e5acd8d07
2022-05-17 18:33:08 +02:00
Fedora Release Engineering
b130695e6f - Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2022-01-22 02:54:24 +00:00
Ondřej Míchal
3a1aa2f691 Add upstream patch fixing doubled error messages 2022-01-09 23:13:42 +02:00
Debarshi Ray
9bebde5bb6 BuildRequire only systemd-rpm-macros
... as recommended by the Fedora packaging guidelines:
https://docs.fedoraproject.org/en-US/packaging-guidelines/Tmpfiles.d/
https://pagure.io/packaging-committee/issue/824
2021-12-10 11:24:35 +01:00
Debarshi Ray
ca91d5a3eb Style fix
No need to issue a build just for this.
2021-12-10 10:05:18 +01:00
Debarshi Ray
deb9c1e8e6 Update URL to point to the website
No need to issue a build just for this.
2021-12-10 05:11:42 +01:00
Debarshi Ray
88b0cbf084 Specify the minimum Meson version
No need to issue a build just for this.
2021-12-10 05:09:40 +01:00
Debarshi Ray
08f687ebe2 Update to 0.0.99.3 2021-12-10 04:47:38 +01:00
Debarshi Ray
70f5d2352c Restore backwards compatibility with existing containers
https://bugzilla.redhat.com/show_bug.cgi?id=1995439
2021-10-26 00:22:22 +02:00
Debarshi Ray
01cc5e6ecc Ensure that binaries are run against their build-time ABI
https://bugzilla.redhat.com/show_bug.cgi?id=1995439
2021-10-22 02:43:56 +02:00
Oliver Gutierrez
c872492676
Rebuilt for gating 2021-09-13 16:02:32 +01:00
Oliver Gutierrez
c41104fe32
Rebuilt for gating tests 2021-09-09 09:37:58 +01:00
Oliver Gutierrez
482da6793f
Bumped version for rerun gating after updating the ansible playbooks 2021-08-23 19:26:50 +01:00
Oliver Gutierrez
4fbf8c365e
Fixed playbooks for gating 2021-08-23 19:25:13 +01:00
Oliver Gutierrez
a6a68d9aae
Version bump to build and check fedora gating 2021-08-20 11:30:18 +01:00