Install a Custom Theme using OpenWRT Image Builder

Hi,

I been building my own firmware using OpenWRT Image builder. I'm trying to install luci-theme-argon from here https://github.com/jerrykuku/luci-theme-argon.

I can install this on OpenWRT using SSH but I like to pre-compile the theme using Image Builder. Any idea how to achieve this?

Here is the command that I usually use to build firmware

make -j4 image PROFILE=xiaomi_mi-router-4c PACKAGES="luci luci-app-upnp luci-app-sqm luci-app-ddns luci-app-wireguard luci-app-adblock stubby tcpdump-mini nano wget ca-certificates ca-bundle xl2tpd"

Also, how can I remove the default theme while compiling firmware?
Thanks

You can grab the IPK from github and put it into packages/ folder of the image builder and it will be available to be included in the PACKAGES variable.

You can remove the packages by prepending them with a minus sign in the PACKAGES variable as well: PACKAGES="luci-theme-argon -luci-theme-openwrt".

Most of the themes I've had experience with activate themselves on install, not sure if argon does.

PS. You use the term pre-compile, which is what people normally use when talking about SDK, not image builder, but given the scope of your thread, I assumed you still meant Image Builder, not SDK.

drwxr-xr-x 10 1000 1000    4096 Jun 20 22:04 .
drwx------ 12 root root    4096 Jun 20 23:48 ..
-rw-r--r--  1 1000 1000  245272 Jun 14 05:36 .config
-rw-r--r--  1 1000 1000 5932643 Jun 14 05:36 .packageinfo
-rw-r--r--  1 root root   19319 Jun 14 22:06 .profiles.mk
-rw-r--r--  1 1000 1000  638221 Jun 14 05:36 .targetinfo
-rw-r--r--  1 1000 1000    8377 Jun 14 05:36 Makefile
drwxr-xr-x  3 root root    4096 Jun 14 22:06 bin
drwxr-xr-x  3 1000 1000    4096 Jun 14 05:36 build_dir
drwxr-xr-x  3 root root    4096 Jun 20 18:43 files
drwxr-xr-x  3 1000 1000    4096 Jun 14 05:36 include
-rw-r--r--  1 root root     176 Jun 14 22:06 key-build
-rw-r--r--  1 root root      92 Jun 14 22:06 key-build.pub
-rw-r--r--  1 root root     356 Jun 14 22:06 key-build.ucert
-rw-r--r--  1 root root     260 Jun 14 22:06 key-build.ucert.revoke
drwxr-xr-x  2 1000 1000    4096 Jun 14 22:06 keys
-rw-r--r--  1 1000 1000     928 Jun 14 05:36 repositories.conf
-rw-r--r--  1 1000 1000   14822 Jun 14 05:36 rules.mk
drwxr-xr-x  4 1000 1000    4096 Jun 14 05:36 scripts
drwxr-xr-x  4 1000 1000    4096 Jun 14 05:36 staging_dir
drwxr-xr-x  3 1000 1000    4096 Jun 14 05:36 target

I'm using Image Builder, however, I'm not seeing any package folder here.

that package is not in default repositories, so you need to download the package file and put it in a folder, then add that folder to repository list of image builder before you can add it

see the docs

Thanks. So I created a directory called packages like
/root/openwrt-imagebuilder-ramips-mt76x8.Linux-x86_64/packages
and added this on repo file like
src custom file:///root/openwrt-imagebuilder-ramips-mt76x8.Linux-x86_64/packages

and it worked! Thanks again.

1 Like

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.