Compile firmware image to include custom bash script file

I have wrote a short bash script that I would like to run using cron in Openwrt. Obviously, the bash file reside in (example) tmp folder which upon reboot, it will go away. Therefore, can someone point me to right direction as how can I go about to include the bash script in the compiled firmware image and place it in a folder (it doesn't matter what folder, either I can create a new folder or put it in existing) And also include a cron task that run the bash file in a timer (such as every 5 minutes).

Is there a file I am suppose to edit (e.g. in target folder under, for example, /linux/ramips/mt7621/)? so that after compile, the bash script will get included in the firmware image.

Thank you!

4 Likes

again, GREATLY APPRECIATE all your help... I will check it out!