Dockerfile for compiling librealsense on Alpine.
See the example
directory.
On x86 Linux, the following may be necessary to install buildx
:
export DOCKER_BUILDKIT=1
docker build --platform=local -o . git://github.com/docker/buildx
mkdir -p ~/.docker/cli-plugins
mv buildx ~/.docker/cli-plugins/docker-buildx
In order to be able to build images for foreign architectures, the docker/binfmt
image should pulled and run. This will make qemu-user-static
available on the host:
docker run --rm --privileged docker/binfmt:a7996909642ee92942dcd6cff44b9b95f08dad64 # latest as of 2020-10-20
docker buildx create --name librealsensebuilder
docker buildx use librealsensebuilder
docker buildx inspect --bootstrap
export DHUBREPO=myrepo
./create_builds.py librealsense > librealsense.hcl
docker login
docker buildx bake --push --file ./librealsense.hcl
The create_builds.py
script output includes the Docker commands above as HCL file comments.