ImageBuilder (Image Generator): how to build all profiles?

Say I have an ImageBuilder for ath79, how can I use it to generate all the ath79 images?

At the moment if I run it without the "PROFILE" argument it generates only one image.

normally, omitting the PROFILE is the way to generate all images, AFIAK. What is the command you are issuing? Does the output indicate any specific devices that fail (such as for lack of space)?

Also, do you really want to build all images? Unless you are building for the entire target for a scenario like providing pre-built community builds and/or you really own/control a large variety of devices, it's usually not really worth building all images if you only need a selected few.


If I run just make image without anything only the image for "ath79 - Ubiquiti Nanostation Loco M XW" is generated.

I do not get any failure, the exit code is 0.

Yes I am sure I want to generate all the images because my goal is to provide an OpenWrt based image for OpenWISP to help people try out the different features of OpenWISP faster via the demo service.

Right now a lot of users get stuck with all the preparations so I am trying to make it simpler for them.

I just downloaded the vanilla image builder of the latest stable version (22.03), at, unpacked it, and run make image on it and it generated these files:


I was curious to see if I tried the default image builder if I would get a different result, so far the generated image is not the same but it's still just one image instead of all the images.

Am I missing something?

I don't use IB, but presumably as in menuconfig:

1 Like
	make manifest PROFILE="<profilename>" # override the default target profile

Theortically, you can adjust the manifest for the proifles, similar to what @anomeome suggetsted (if I had to guess, the menuconfig options end up writing this manifest, so they're probably equivalent)

1 Like

Thanks for your help!

I am trying to build with CONFIG_TARGET_MULTI_PROFILE=y.
I am pretty sure this is what was missing before.

I get the following error:

# create an empty package index so `opkg` doesn't report an error
touch ~/openwrt/build_dir/target-mips_24kc_musl/owf-imagebuilder-22.03-ath79-generic.Linux-x86_64/packages/Packages
install -m0644 ./files/ ~/openwrt/build_dir/target-mips_24kc_musl/owf-imagebuilder-22.03-ath79-generic.Linux-x86_64/packages/
echo ''                                                        >> ~/openwrt/build_dir/target-mips_24kc_musl/owf-imagebuilder-22.03-ath79-generic.Linux-x86_64/repositories.conf
echo '## This is the local package repository, do not remove!' >> ~/openwrt/build_dir/target-mips_24kc_musl/owf-imagebuilder-22.03-ath79-generic.Linux-x86_64/repositories.conf
echo 'src imagebuilder file:packages'                          >> ~/openwrt/build_dir/target-mips_24kc_musl/owf-imagebuilder-22.03-ath79-generic.Linux-x86_64/repositories.conf
find ~/openwrt/bin/targets/ath79/generic/packages ~/openwrt/bin/packages/mips_24kc/base ~/openwrt/bin/packages/mips_24kc/coova ~/openwrt/bin/packages/mips_24kc/luci ~/openwrt/bin/packages/mips_24kc/openwisp ~/openwrt/bin/packages/mips_24kc/openwisp_monitoring ~/openwrt/bin/packages/mips_24kc/packages -type f -name '*.ipk' \
	-exec cp -fpR -t ~/openwrt/build_dir/target-mips_24kc_musl/owf-imagebuilder-22.03-ath79-generic.Linux-x86_64/packages/ {} +
echo ''                                                        >> ~/openwrt/build_dir/target-mips_24kc_musl/owf-imagebuilder-22.03-ath79-generic.Linux-x86_64/repositories.conf
echo 'option check_signature'                                  >> ~/openwrt/build_dir/target-mips_24kc_musl/owf-imagebuilder-22.03-ath79-generic.Linux-x86_64/repositories.conf
install -d -m0755 ~/openwrt/build_dir/target-mips_24kc_musl/owf-imagebuilder-22.03-ath79-generic.Linux-x86_64/keys
cp -fpR -L ~/openwrt/staging_dir/target-mips_24kc_musl/root-ath79/etc/opkg/keys/ ~/openwrt/build_dir/target-mips_24kc_musl/owf-imagebuilder-22.03-ath79-generic.Linux-x86_64/
cp: cannot stat '~/openwrt/staging_dir/target-mips_24kc_musl/root-ath79/etc/opkg/keys/': No such file or directory
make[3]: *** [Makefile:45: ~/openwrt/bin/targets/ath79/generic/owf-imagebuilder-22.03-ath79-generic.Linux-x86_64.tar.xz] Error 1
make[3]: Leaving directory '~/openwrt/target/imagebuilder'
time: target/imagebuilder/install#0.15#0.09#0.29
    ERROR: target/imagebuilder failed to build.
make[2]: *** [target/Makefile:30: target/imagebuilder/install] Error 1
make[2]: Leaving directory '~/openwrt'
make[1]: *** [target/Makefile:24: ~/openwrt/staging_dir/target-mips_24kc_musl/stamp/.target_install] Error 2
make[1]: Leaving directory '~/openwrt'
make: *** [~/openwrt/include/ world] Error 2

Seems to get stuck with opkg keys. Any hint on how to resolve this?