Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

podman: new package #20

Draft
wants to merge 37 commits into
base: upstream-master
Choose a base branch
from
Draft

podman: new package #20

wants to merge 37 commits into from

Conversation

paralin
Copy link
Collaborator

@paralin paralin commented Jul 24, 2022

podman is a CLI tool for spawning and runnign containers according to the OCI
specification.

This commit adds both a host and target podman package.

https://github.com/containers/podman

Signed-off-by: Christian Stewart christian@paral.in

TODO:

  • add catatonit package
  • add crun package

Signed-off-by: Christian Stewart <christian@paral.in>
automated build + check-package + legal-info.

Signed-off-by: Christian Stewart <christian@paral.in>
Signed-off-by: Christian Stewart <christian@paral.in>
Signed-off-by: Christian Stewart <christian@paral.in>
Signed-off-by: Christian Stewart <christian@paral.in>
Signed-off-by: Christian Stewart <christian@paral.in>

---

v2 -> v3:

 - fixed newline at end of config.in.host file

TODO for V4:

https://patchwork.ozlabs.org/project/buildroot/patch/20210516010521.1375959-1-christian@paral.in/

 - changes to patch to add libfuse3 as host package requested.
Img is a standalone, daemon-less, unprivileged Dockerfile and OCI compatible
container image builder. It uses the moby-buildkit solver internally. The
commands/UX mirror the Docker CLI for workflow compatibility.

Using the genuinetools- prefix due to the generic nature of the "img" name.

Adds both host and target variants. fuse-overlayfs can be used as an
unprivileged and rootless overlay filesystem backend.

https://github.com/genuinetools/img

Signed-off-by: Christian Stewart <christian@paral.in>

---

TODO:

https://patchwork.ozlabs.org/project/buildroot/patch/20210516010521.1375959-1-christian@paral.in/

 - changes to patch to add libfuse3 as host package requested.
Tested on Pi4 Model B (aarch64).

Signed-off-by: Christian Stewart <christian@paral.in>

---

Note: this needs adjustment as per comments from upstream:

 - GLX is marked as provided when it's not on arm64
For a full changelog, please see the repository:

https://github.com/raspberrypi/firmware

Signed-off-by: Christian Stewart <christian@paral.in>
This series is currently marked "stable" on the gentoo repo.

Signed-off-by: Christian Stewart <christian@paral.in>
Signed-off-by: Christian Stewart <christian@paral.in>
Adds both host and target packages for buildah.

Buildah is a tool that facilitates building OCI images.

https://github.com/containers/buildah

The buildah tree does not ship with a default policy.json file, and instead
relies on packagers to provide one. A patch is added to create a basic barebones
policy.json which is installed to /etc/containers/policy.json with a hook.

Signed-off-by: Christian Stewart <christian@paral.in>

---

v1 -> v2:

 - add package to developers
 - add host runc dependency for host package
 - add libgpgme runtime dependency

v2 -> v3:

 - add policy.json to target: required by some commands
 - example: buildah pull docker.io/library/alpine
 - pull: tested on raspberry pi 4
Adds support for USB rtl8821cu wifi cards.

Similar to rtl8821au and rtl8812au-aircrack-ng packages.

https://github.com/morrownr/8821cu-20210118

Signed-off-by: Christian Stewart <christian@paral.in>
Daemonize is a command line utility to run a program as a Unix daemon.

Signed-off-by: Christian Stewart <christian@paral.in>

---

TODO: Changes requested for v2:

https://patchwork.ozlabs.org/project/buildroot/patch/20210124102241.1207866-1-christian@paral.in/
Lack of an RNG source can block boot-up on headless systems with few hardware
entropy sources. This patch allows rngd to start earlier than the current
"basic.target" when systemd is used. Removing the dependency on "basic.target"
and by extension, "sockets.target" will allow rngd to start before, for example,
docker.sock - which can take some time to become ready without entropy.

This is a cherry-pick of a peer project patch:

https://patchwork.openembedded.org/patch/163303/

Signed-off-by: Christian Stewart <christian@paral.in>
Switch to the skiffos fork which has additional features:

 - Try to use findmnt to lookup mountpoint information.
 - If findmnt fails, fallback to the older approach.
 - Add no-resize-partition and ignore-resize-partition flags.

Signed-off-by: Christian Stewart <christian@paral.in>
Signed-off-by: Christian Stewart <christian@paral.in>
Add a symlink to the expected location for vpdma-1ba in the root of the firmware directory.

Signed-off-by: Christian Stewart <christian@paral.in>
Android bootimg utilities: mkbootimg and unpackbootimg.

Signed-off-by: Christian Stewart <christian@paral.in>
Adds 1 patch to fix an install error when building as a host package.

Patch was submitted upstream:
libfuse/libfuse#598

Signed-off-by: Christian Stewart <christian@paral.in>

---

v1 -> v2:

 - adjusted patch to completely remove init.d script install

TODO for V3:

https://patchwork.ozlabs.org/project/buildroot/patch/20210516010521.1375959-1-christian@paral.in/

 - add init.d scripts for openrc and systemd
Signed-off-by: Christian Stewart <christian@paral.in>
Fixes errors when lz4 package was already installed previously.

Signed-off-by: Christian Stewart <christian@paral.in>
Signed-off-by: Christian Stewart <christian@paral.in>
Update to latest 5.1.1.r38 from 4.2.2.

Dropped old patches and added several compat patches.

Signed-off-by: Christian Stewart <christian@paral.in>
Switching to the lwfinger fork of rtl8821au USB WiFi kernel module.

This fixes build errors against kernel 5.18.

This patch also drops all of the patches that were previously maintained in the
Buildroot tree, which are no longer necessary.

It should be noted that rtl8812au-aircrack-ng provides the same driver.

Signed-off-by: Christian Stewart <christian@paral.in>
Signed-off-by: Christian Stewart <christian@paral.in>
Signed-off-by: Christian Stewart <christian@paral.in>
@paralin paralin marked this pull request as draft July 25, 2022 00:14
@paralin paralin self-assigned this Jul 25, 2022
Use go mod init to convert other tool files and create go.mod properly.

Signed-off-by: Christian Stewart <christian@paral.in>
Enabling the C stack protector for Cgo causes a build failure on i386:

runtime/cgo(.text): unknown symbol __stack_chk_fail_local in pcrel
runtime/cgo(.text): unknown symbol __stack_chk_fail_local in pcrel
runtime/cgo(.text): unknown symbol __stack_chk_fail_local in pcrel
runtime/cgo(.text): unknown symbol __stack_chk_fail_local in pcrel
runtime/cgo(.text): unknown symbol __stack_chk_fail_local in pcrel
runtime/cgo(.text): relocation target __stack_chk_fail_local not defined
runtime/cgo(.text): relocation target __stack_chk_fail_local not defined

Add: CGO_CFLAGS=-fno-stack-protector

golang/go#52919

Set CGO_CFLAGS and other flags while building Go with make.bash as well.

Signed-off-by: Christian Stewart <christian@paral.in>
Go 1.19 is a major release with changes to the implementation of the toolchain,
runtime, and libraries.

Dropped patch 0002-cmd-dist-use-gohostarch... as it was merged upstream.

https://go.dev/doc/go1.19

Signed-off-by: Christian Stewart <christian@paral.in>
 - Updated version to v251.
 - Changed hash for v251 download file.
 - Updated hash for LICENSES/README.md
 - Removed outdated patch 0001-missing-syscall...

https://github.com/systemd/systemd/releases/tag/v251

Signed-off-by: Christian Stewart <christian@paral.in>
All Go compiler versions > 1.4.x (old) are written in Go, and require a existing
compiled Go version to use to build from source.

https://golang.org/doc/install/source#bootstrapFromSource

The process for "bootstrapping" the Go compiler in Buildroot is:

1. Compile a C/C++ cross-compiler (gcc) as the host toolchain.
2. Build go-bootstrap (which is Go 1.4.x and written in C)
3. Build go 1.16.x (written in Go) using go-bootstrap.

The problem is that step 2 - build go-bootstrap - does not work on 64-bit arm.
The Go compiler from 1.4.x is compatible with x86, x86_64, and arm (32 bit).

This patch instead uses the host Go compiler to bootstrap host-go when
BR2_PACKAGE_HOST_GO_BOOTSTRAP_ARCH_SUPPORTS is not set. This is similar to how
the host GCC is used to bootstrap the Buildroot toolchain.

Signed-off-by: Christian Stewart <christian@paral.in>

---

v1 -> v2:

 - thanks Thomas for the review & suggestions
 - added NEEDS_HOST_GO boolean
 - added dependency checks to support/dependencies/dependencies.sh
 - removed unnecessary changes to go-bootstrap package

v2 -> v3:

 - add dependency on toolchain if Cgo is enabled

Signed-off-by: Christian Stewart <christian@paral.in>
Signed-off-by: Christian Stewart <christian@paral.in>
Signed-off-by: Christian Stewart <christian@paral.in>
@paralin paralin force-pushed the podman branch 2 times, most recently from e07d913 to b8fdc37 Compare August 21, 2022 03:15
crun is a fast and low-memory OCI Container Runtime in C.

https://github.com/containers/crun

This version of the package compiles libocispec statically as a submodule.

The WIP version of the libocispec package is available:

6ebb46b

Signed-off-by: Christian Stewart <christian@paral.in>
podman is a CLI tool for spawning and runnign containers according to the OCI
specification.

This commit adds both a host and target podman package.

https://github.com/containers/podman

Signed-off-by: Christian Stewart <christian@paral.in>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant