Commit Graph

85 Commits

Author SHA1 Message Date
Jan Kaluza a0a9ac6380 Switch common, storage and image to monorepo.
Signed-off-by: Jan Kaluza <jkaluza@redhat.com>
2025-08-29 15:04:28 +02:00
tomsweeneyredhat cce5f9c32b Bump to Buildah v1.42.0-dev
Bump to the next dev version of Buildah, v1.42.0-dev
for the upstream main branch.

Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
2025-07-16 21:19:45 -04:00
tomsweeneyredhat 9f185b7777 Bump to Buildah v1.41.0
Bump Buildah to v1.41.0 in preparation for
Podman v5.6.0

Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
2025-07-16 21:19:45 -04:00
tomsweeneyredhat 36adabb2d6 Bump to Buildah v1.41.0-dev
Bump the main Buildah branch to the next dev version,
Buildah v1.41.0-dev

Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
2025-04-17 15:21:28 -04:00
tomsweeneyredhat ff62e3e8a5 Bump Buildah to v1.40.0
Bump Buildah to v1.40.0 in preparation
for Podman v5.5.0

Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
2025-04-17 15:21:28 -04:00
flouthoc a4bc357820
build: return ExecErrorCodeGeneric when git operation fails
Only propagate error message from git and let buildah reflect error code
`125`.

Reason: Buildah should return predicatable error code from the set of
defined error codes in exec_codes.go at https://github.com/containers/buildah/blob/main/pkg/cli/exec_codes.go#L6
anything other that predefined error codes introduces inconsistency thus making testing difficult in CI and podman.

Users should expect buildah to refect ExecErrorCodeGeneric with error message kept intact from the underlying `git`
commands.

Signed-off-by: flouthoc <flouthoc.git@gmail.com>
2025-03-28 07:06:44 -07:00
flouthoc 0c377816a9
add: report error while creating dir for URL source.
Correctly report back error when attempting to create `Tmpdir` for a
given url source.

Also remove superfluous `isGitTag` from define/types.go since `git
fetch` correctly resolves by provided reference.

Closes: https://github.com/containers/podman/issues/25679

Signed-off-by: flouthoc <flouthoc.git@gmail.com>
2025-03-26 08:10:59 -07:00
tomsweeneyredhat 6c3d7546e3 Bump to Buildah v1.40.0-dev
Bumping back to a dev version.

Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
2025-01-31 18:19:08 -05:00
tomsweeneyredhat c15ab104a1 Bump to Buildah v1.39.0
Bump to Buildah v1.39.0 in preparation
for Podman v5.4

Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
2025-01-31 18:15:22 -05:00
Nalin Dahyabhai c30f5784da define.TempDirForURL(): always use an intermediate subdirectory
Ensure that the temporary directory that we create is never itself the
top-level directory of the content that we're downloading, in case it's
an archive which includes a "." with weird permissions.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
2025-01-17 09:59:55 -05:00
tomsweeneyredhat 147765b45c Bump to Buidah v1.39.0-dev
Bump top of tree back to the next dev version.

[NO NEW TESTS NEEDED]

Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
2024-11-08 16:25:44 -05:00
tomsweeneyredhat 7aa3b5ee04 Bump to Buildah v1.38.0
Bump to Buildah v1.38.0 in preparation of Podman v5.3.0

[NO NEW TESTS NEEDED]

Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
2024-11-08 16:25:44 -05:00
danishprakash 71fc845d0b
tests/bud.bats: add git source
Signed-off-by: Danish Prakash <contact@danishpraka.sh>
2024-09-09 12:45:15 +05:30
danishprakash 47297b3d5c
add: add support for git source
Signed-off-by: Danish Prakash <contact@danishpraka.sh>
2024-09-09 12:45:15 +05:30
Nalin Dahyabhai 8ae99121c1 CI: enable the gofumpt linter
Turn on the gofumpt linter.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
2024-08-15 13:17:44 -04:00
tomsweeneyredhat 4e78b5723c Bump to Buildah v1.38.0-dev
Bump Buildah's main branch to the next dev release.

[NO NEW TESTS NEEDED]

Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
2024-07-26 09:48:25 -04:00
tomsweeneyredhat f9de1bbd1f Buildah v1.37.0
Bump Buildah to v1.37.0 in preparation for Podman v5.2

[NO NEW TESTS NEEDED]

Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
2024-07-26 09:47:33 -04:00
tomsweeneyredhat f39d5fba25 Bump to v1.37.0-dev
As the title says.  Setting to v1.37.0-dev after
creatings Buildah v1.36.0 for release with Podman v5.1

[NO NEW TESTS NEEDED]

Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
2024-05-23 16:31:33 -04:00
tomsweeneyredhat 6ceba8838d Bump to v1.36.0
[NO TESTS NEEDED]

Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
2024-05-23 16:31:28 -04:00
tomsweeneyredhat da81d2e2b4 Bump to v1.36.0-dev
As the title says.  Bumping back to the next dev
version.

[NO NEW TESTS NEEDED]

Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
2024-03-06 23:47:45 -05:00
tomsweeneyredhat fedbd79676 Bump v1.35.0
Bump to Buildah v1.35.0 in preparation of Podman v5.0.

[NO NEW TESTS NEEDED]

Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
2024-03-06 23:47:45 -05:00
tomsweeneyredhat d73e211205 Bump main to v1.35.0-dev
There have been a number of breaking changes added
since v1.34 to the main branch.  We'll create a new
release branch for v1.34 and will set the version in
main to 1.35.0-dev.

The intended target for Buildah v1.35 is Fedora 40.

[NO NEW TESTS NEEDED]
Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
2024-02-08 10:42:20 -05:00
Daniel J Walsh 79fb3c2135
Make buildah match podman for handling of ulimits
Podman currently sets the ulimits of nofile and nproc
to max in rootless mode, if the user does not override.

Buildah on the other hand just passes in the current defaults.

Podman build should match podman run, and this will fix that problem.

Fixes: https://github.com/containers/buildah/issues/5273

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2024-01-31 15:28:51 -05:00
Nalin Dahyabhai cf69e8a187 build,commit: add --sbom to scan and produce SBOMs when committing
Add a --sbom flag to `buildah build` and `buildah commit` which will
scan the rootfs and specified context directories to build SPDX or
CycloneDX SBOMs and lists of package URLs.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
2024-01-19 13:55:57 -05:00
Nalin Dahyabhai 81435aadcb mkcw: populate the rootfs using an overlay
When using the working container's rootfs to populate a plaintext disk
image with mkfs, instead of writing .krun_config.json to the rootfs and
then removing it afterward (since we don't want it to show up if the
same working container is later committed to non confidential-workload
image), mount an overlay filesystem using a temporary directory as the
upper and the rootfs as the lower, create the .krun_config.json file in
the overlay filesystem, and use the overlay filesystem as the source
directory for mkfs.

Add the necessary stubs to allow pkg/overlay to at least compile on
non-Linux systems.  Change the naming scheme for a test so that the path
names it uses for temporary directories don't include "," or "=", which
can confuse the kernel.

Creating confidential workload images will now only be possible on Linux
systems, but we exec'd out to sevctl to read platform certificates, and
that requires kernel support with vendor firmware, so I don't know that
anyone will actually be impacted by the change.

Teach pkg/overlay.MountWithOptions() to accept `nil` as a pointer to a
struct parameter that is otherwise optional.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
2023-12-13 14:06:59 -05:00
TomSweeneyRedHat 4276a735b3 Bump to v1.34.1-dev
As the title says

[NO NEW TESTS NEEDED]

Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
2023-12-11 17:35:11 -05:00
TomSweeneyRedHat 21ec7aceb2 Bump to v1.34.0
[NO TESTS NEEDED]

Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
2023-12-11 17:35:04 -05:00
TomSweeneyRedHat bd0ae2affa Bump to v1.33.2-dev
Bump to v1.33.2-dev

[NO NEW TESTS NEEDED]

Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
2023-11-18 23:42:50 -05:00
TomSweeneyRedHat 38d6d5f114 Bump to v1.33.1
Bump to 1.33.1 to fix misbump to 1.31.1 (Ugh!)

[NO NEW TESTS NEEDED]

Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
2023-11-18 23:41:18 -05:00
TomSweeneyRedHat 6d66008b67 Bump to v1.31.2-dev
As the title says.

[NO NEW TESTS NEEDED]

Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
2023-11-18 19:35:59 -05:00
TomSweeneyRedHat f18868d066 Bump to v1.31.1
As the title says.  Quick fix for Podman test issue
and BuildKit CVE.

[NO TESTS NEEDED]

Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
2023-11-18 19:32:43 -05:00
TomSweeneyRedHat 8fb8261771 Bump to v1.33.1-dev
As the title says

[NO NEW TESTS NEEDED]

Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
2023-11-17 15:22:50 -05:00
TomSweeneyRedHat 98da6c8d6a Bump to v1.33.0
As the title says

[NO TESTS NEEDED]

Signed-off-by: TomSweeneyRedHat <tsweeney@redhat.com>
2023-11-17 15:21:08 -05:00
Daniel J Walsh 8df9b760b3
Stop using DefaultNetworkSysctl and use containers.conf only
Also mark uses of DefaultCapabilities as Deprecated.

Fixes: https://github.com/containers/buildah/issues/5155

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2023-11-13 11:46:04 -05:00
Nalin Dahyabhai abc57f8df2 Bump to v1.33.0-dev
Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
2023-09-14 13:19:10 -04:00
Nalin Dahyabhai 2326d4929f Tag v1.32.0
[NO NEW TESTS NEEDED]

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
2023-09-14 13:18:55 -04:00
Nalin Dahyabhai e89fac6c9b Add `buildah mkcw`, add `--cw` to `buildah commit` and `buildah build`
Add a --cw option to `buildah build` and `buildah commit`, which takes a
comma-separated list of arguments and produces an image laid out for use
as a confidential workload:
  type: sev or snp
  attestation_url: location of a key broker server
  cpus: expected number of virtual CPUs to run with
  memory: expected megabytes of memory to run with
  workload_id: a distinguishing identifier for the key broker server
  ignore_attestation_errors: ignore errors registering the workload
  passphrase: for encrypting the disk image
  slop: extra space to allocate for the disk image

At least one of attestation_url and passphrase must be specified in
order for the encrypted disk image to be decryptable at run-time.  Other
arguments can be omitted.  ignore_attestation_errors is intentionally
undocumented, as it's mainly used to permit some amount of testing on
systems which don't have the required hardware.

Add an `mkcw` top-level command, for converting directly from an image
to a confidential workload.

Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
2023-09-07 14:05:10 -04:00
Tom Sweeney e00845797c Bump to v1.32.0-dev
As the title says. In preparation for RHEL 8.9./9.3

[NO NEW TESTS NEEDED]

Signed-off-by: Tom Sweeney <tsweeney@redhat.com>
2023-06-30 10:46:06 -04:00
Tom Sweeney d0de60bbf3 Bump 1.31.0
As the title says.  In preparation of RHEL 8.9/9.3

[NO NEW TESTS NEEDED]

Signed-off-by: Tom Sweeney <tsweeney@redhat.com>
2023-06-30 10:39:59 -04:00
tomsweeneyredhat e9884fc41c
Bump to v1.31.0-dev
As the title says

[NO NEW TESTS NEEDED]

Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
2023-04-08 07:03:28 -04:00
tomsweeneyredhat 04965f1198
Bump to v1.30.0
[NO TESTS NEEDED]

Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
2023-04-08 07:03:27 -04:00
Lokesh Mandvekar 78416393ff
[CI:BUILD] Packit: Enable Copr builds on PR and commit to main
This commit adds Packit configuration files which will trigger rpm
builds on copr:`rhcontainerbot/packit-builds` on every PR as well as on
copr:`rhcontainerbot/podman-next` on every commit to main branch.

This commit will ensure main branch is always buildable on all supported
Fedora and CentOS Stream versions for aarch64 and x86_64.
TODO: enable build checks for s390x and ppc64le while ensuring they
don't take too long to build.

The packit builds reuse `buildah.spec.rpkg` present upstream and are
thus independent of Fedora / CentOS dist-git.

This change will remove the need for the current webhook based triggering
of rpm builds on rhcontainerbot/podman-next after commit to main.
That will be instead handled by the `trigger: commit` action added in this
PR. New builds will continue to get posted to the same link so users
don't need to change any existing copr repo configuration.

[NO NEW TESTS NEEDED]

Signed-off-by: Lokesh Mandvekar <lsm5@fedoraproject.org>
2023-03-23 16:03:58 +05:30
tomsweeneyredhat 2008a5302d Bump to v1.30.0-dev
Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
2023-01-25 18:24:47 -05:00
tomsweeneyredhat 94b723cb5b Bump to v1.29.0
As the title says.

[NO NEW TESTS NEEDED]

Signed-off-by: tomsweeneyredhat <tsweeney@redhat.com>
2023-01-25 18:22:54 -05:00
Chris Evich 46eea31588
Replace io/ioutil calls with os calls
In golang 1.19, `io/ioutil` is fully deprecated preventing Buildah from
compiling.  Replace all calls with equivalent calls from the `os`
package.

Signed-off-by: Chris Evich <cevich@redhat.com>
2022-12-06 14:29:32 -05:00
Doug Rabson 5e792e97b0 version: Bump to 1.29.0-dev
[NO TESTS NEEDED]

Signed-off-by: Doug Rabson <dfr@rabson.org>
2022-11-30 11:25:31 +00:00
Daniel J Walsh eae3415b1e
Bump to v1.28.1-dev
[NO TESTS NEEDED]

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2022-09-30 21:38:43 -04:00
Daniel J Walsh 79f41e3235
Bump to v1.28.0
[NO TESTS NEEDED]

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2022-09-30 21:38:43 -04:00
Daniel J Walsh 8d5d763213
Fix stutters
Podman adds an Error: to every error message. So starting an error
message with "error" ends up being reported to the user as

Error: error ...

This patch removes the stutter.

Also ioutil.ReadFile errors report the Path, so wrapping the err message
with the path causes a stutter.

Signed-off-by: Daniel J Walsh dwalsh@redhat.com

[NO NEW TESTS NEEDED]

Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
2022-09-19 07:11:44 -04:00
Aditya R 3a6919b5c0 version: bump to 1.28.0-dev
[NO NEW TESTS NEEDED]
[NO TESTS NEEDED]

Signed-off-by: Aditya R <arajan@redhat.com>
2022-08-08 17:09:19 +05:30