2 #---------------------------------------------------------#
3 # Upgrade Automation Script
7 # 1. Download images (old, new)
8 # 2. Download old image to target
10 # 4. Download delta to target
11 # 5. Execute upgrade trigger
13 # This script covers steps after delta (4, 5 step)
15 #---------------------------------------------------------#
19 echo "Usage: upgrade-automation.sh UPDATE_PACKAGE"
25 TOTA_DIR=/opt/usr/data/fota
27 sdb shell mkdir -p ${TOTA_DIR}
29 # 4. Download delta to target
30 sdb push ${UPKG} ${TOTA_DIR}/delta.tar
32 # 5. Execute upgrade manager
33 sdb shell tar xvfp ${TOTA_DIR}/delta.tar -C ${TOTA_DIR} upgrade-trigger.sh
34 sdb shell ${TOTA_DIR}/upgrade-trigger.sh ${TOTA_DIR}/delta.tar