Docker openwrt

hello guys. is there any way to install openwrt using home assistant in docker?

Something like this?

so if i understand it correct i just create a image that i then upload to the docker in home assistant?

No idea; I've never run OpenWRT inside Docker before.

Couldn't hurt to try, right? Experimentation, trial-and-error, and document your findings.

i found how to download the image builder but it says this

Does https://duckduckgo.com/?q="invalid+tar+magic" help?

no i already went to few links but it didnt help

How about https://duckduckgo.com/?q="invalid+tar+magic"+"xz" instead? That search is tailored more towards extracting from .xz files specifically.

i think the problem is the file i downloaded. i might just be stupid. i found the file here: https://archive.openwrt.org/releases/22.03.2/targets/bcm27xx/bcm2710/. downloaded it with wget in the openwrt and tried to unzip it. thats when i failed

Any particular preference for 22.03.2 over 22.03.5? Is https://archive.openwrt.org/releases/22.03.5/targets/bcm27xx/bcm2710/ not suitable?

i set up this openwrt in january. so thats probably why it has this version. but i can certainly update it.

Unlikely. Do a SHA256 checksum against it to be sure, though.

Also unlikely. You're already breaking the mould by trying something new, namely OpenWRT. That does not suggest stupidity; it suggests curiosity.

However, your responses suggest a certain hesitation about trying things to see if they work and/or break. For example, the very first result in one of the above searches suggested installing the full tar package, as it has fewer limitations than the tar component of Busybox.

Did you see the same result, and did you try installing the full tar package?

its done. now the site says to type "make image" but it says make not found.

Did you install make?

oh my god i didnt. my brain is so out right now :joy:

1 Like

so last error. if it doesnt work im probably quiting.


i type make image and it says error that i totally dont undertand.

"Exec format error" means you're trying to run a binary program compiled for one architecture on a different architecture. E.g. you can't run x86 programs on ARM, and vice-versa. Some Docker images are compiled only for x86, or only for ARM. Other Docker images are compiled for multiple architectures.

Have fun diving down the architecture rabbit hole... :slight_smile:

im giving up for now. maybe ill come back for it later. :pensive:

Sometimes a break helps. Sometimes a night's sleep does the trick. Step away for a bit, then come back with fresh eyes.

2 Likes

Be aware that running OpenWrt in a container is not a supported configuration and may cause various forms of failures and security issues! OpenWrt expects to be run on its own kernel, with its own kernel patches (changing security relevant behaviour), with its own sysctl based preconfiguration and expects to be able to load- and unload kernel modules as needed (which isn't possible in a container).

Please prefer full system virtualization (which does not have these issues) over container based solutions, see e.g. kvm (qemu), xen, hyper-v, virtualbox, parallels, vmware.

2 Likes