Revert "Revert "Add check for local OTA_FROM_TARGET_SCRIPT""

This reverts commit 0723a6eaceadc0db629479adb1a0f2201a18caa6.