Adding backup archive into build image?

Hello people, I'm currently learning openwrt, and am currently building images for my RPi4 and I wondered if it's possible to include my backup config file into the build process so I don't need to restore backups etc manually.

I'm using the "build system" not "imagebuilder" if that changes things.

Put all files under ./files/ in the build root dir while preserving the folder structure.

2 Likes

I don't seem to have a "build too" directory??

build root dir

1 Like

So I've extracted the back up, it's given me a 'etc' folder, inside of which is more folders and files.

I put that entire folder into the openwrt directory on my build system?

The build directory is the directory you change to to run make menuconfig and make. A "files" directory under that build directory may not exist, so create it if necessary. Change to the files directory and extract your config backup tar. For example the wireless config will be the file BUILDDIR/files/etc/config/wireless.

2 Likes

Ah I see now, I open a terminal and use 'cd openwrt' so that's my buildroot.

So in that openwrt folder, I've made a folder called 'files' as one didn't exist, into which I extracted my backup, so my structure now looks like your suggested it would.

So now all I need to do is, build another image.

Git pull, then update and install the scripts, run make menuconfig again if not it gives a warning about it being out of date, then finally run the make command and it will give me my new build but with my backup settings 'baked in' so to speak...

Thank you very much both of you for the assistance. It's very much appreciated.

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