diff options
author | Runar Borge <runar@borge.nu> | 2020-07-09 23:09:21 +0200 |
---|---|---|
committer | Runar Borge <runar@borge.nu> | 2020-07-14 12:30:40 +0200 |
commit | 60d36ca64f43167595077edff287d7ef29eb3b60 (patch) | |
tree | e2f299171d349cf634152031f4de9b4b02d94397 /docker/Dockerfile | |
parent | c7b0a8897cfa8573993f593fc2ed61e981a745a0 (diff) | |
download | vyos-build-60d36ca64f43167595077edff287d7ef29eb3b60.tar.gz vyos-build-60d36ca64f43167595077edff287d7ef29eb3b60.zip |
T1927: arm: Readd CI build of emulated ARM64 container
After a successfull CI build of this container it is considered working and
is possible to add back to the build as a standard target.
The container is changed so it handles an architecture change without changing the dockerfile
Diffstat (limited to 'docker/Dockerfile')
-rw-r--r-- | docker/Dockerfile | 28 |
1 files changed, 16 insertions, 12 deletions
diff --git a/docker/Dockerfile b/docker/Dockerfile index b2a5315c..c892b64b 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -17,22 +17,26 @@ # volume mapped in order to easy export images # This Dockerfile is installable on both x86, x86-64, armhf and arm64 systems -# To install using native cpu instructionset use the default docker `FROM` statement -# (Use this to build on an x86/x86-64 pc/server and on an ARM system, eg. RaspberryPi) -FROM debian:buster +ARG ARCH= +FROM ${ARCH}debian:buster # It is also possible to emulate an arm system inside docker, # execution of this emulated system needs to be executed on an x86 or x86-64 host. -# To install an qemu emulated armhf or arm64 cpu comment out the default `FROM` statement -# and use one of the following instead. -# ARMHF: -#FROM multiarch/debian-debootstrap:armhf-buster-slim -# ARM64: -#FROM multiarch/debian-debootstrap:arm64-buster-slim - -# Prior of installing an emulated qemu build you need to install qemu, qemu-user-static -# and register qemu inside docker using: +# To install using a non-native cpu instructionset use the `--build-arg ARCH=<ARCH>/` +# Supported architectures: +# arm32v6/ +# arm32v7/ +# arm64v8/ +# Example bo byukd natively: +# docker build -t vyos-build:current . +# Example to build on armhf: +# docker build -t vyos-build:current-armhf --build-arg ARCH=arm32v7/ . +# Example to build on arm64: +# docker build -t vyos-build:current-arm64 --build-arg ARCH=arm64v8/ . + +# On some versions of docker the emulation framework is not installed by default and +# you need to install qemu, qemu-user-static and register qemu inside docker manually using: # `docker run --rm --privileged multiarch/qemu-user-static:register --reset` |