/bpf-dev-docker

A dockerized environment for BPF development

Primary LanguageDockerfile

A container to build Linux bpf-next tree and be able to run tools/testing/selftests/bpf/vmtest.sh.

./build-docker.sh will build a docker image based on Debian (bullseye) with qemu, llvm and pahole installed.

./start-docker.sh will run this image under current user, mounting a repo directory (default ./linux) and ~/.bpf_selftests and passing /dev/kvm device.

kernel-build.config is a sample config for kernel build. You may copy it to the repo dir on the host (e.g. ./linux) and then generate an actual config with a command like this one:

/opt/linux$ ./scripts/kconfig/merge_config.sh \
    tools/testing/selftests/bpf/config \
    tools/testing/selftests/bpf/config.vm \
    tools/testing/selftests/bpf/config.x86_64 \
    ./kernel-build.config