bluebox

command module
v0.0.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 1, 2024 License: MIT Imports: 7 Imported by: 0

README

bluebox Go Go Reference

bluebox is intended to fast build a low overhead environment to be able to run tests against Linux kernel APIs like netlink or ebpf. It embeds given statically linked executables into the resulting archive. In a virtual environment with this archive the embedded executables will be executed in a sequential order. bluebox does not provide a shell or other executables.

Installation

$ go install github.com/florianl/bluebox@latest

API

Note: APIs subject to change while bluebox is still in an experimental phase. You can use it but we suggest you pin a version with your package manager of choice.

Example usage

In the following example qemu-system-x86_64 is required to start the virtual environment. For the kernel image a self compiled kernel or a prepared kernel like they are offered by github.com/cilium/ci-kernels can be used. If the kernel is compiled for a different architecture, then a different version of qemu is required as well bluebox also need to know about the target architecture.

  # Generate a very basic initial ramdisk
$ bluebox -o my-initramfs.cpio
  # Boot a kernel in a virtual environment with the generated archive
$ qemu-system-x86_64 -m 4096 -kernel my-linux.bz -initrd my-initramfs.cpio

A more detailed example of how bluebox can be used is given in EXAMPLE.md.

Requirements

A version of Go that is supported by upstream

Similar projects

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
Package initramfs provides functionality to generate an archive, which can be extracted by the Linux kernel when the kernel boots up.
Package initramfs provides functionality to generate an archive, which can be extracted by the Linux kernel when the kernel boots up.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL