Auto-restore customizations after firmware upgrade

I have a handful of cusomizations I use in my MyClouds.  They’re all wiped out during firmware upgrades but can be easily restored with a script.

Here’s my challenge. One of my MyClouds is at a remote location, connecting to my location via OpenVPN

(note: The remote MyCloud is behind a firewall that I do NOT have access to.)

After a firmware upgrade, my OpenVPN config will be wiped and my remote access to that MyCloud will go bye-bye.

Does anyone have an idea how I could trigger a restore script to run automatically, following a firmware upgrade?

Could I plant something in /etc/init.d/ or does that get wiped too?

I welcome any ideas or input.

Thanks for reading

Firmware upgrade will wipe /dev/md0 (md1), so all data will be lost. There only one option to save your config - modify UpgradeFromFile.sh script.

Also this script will save configs from /etc/wdcomp.d and /etc/nas folders (Not all).

Download any firmware, unpack it by dpkg -e *.deb any_folder and see what you get in.

Fox_exe wrote:

Firmware upgrade will wipe /dev/md0 (md1), so all data will be lost. There only one option to save your config - modify UpgradeFromFile.sh script.

Outstanding. I’ll look into that.

Thank you.