projects
/
openwrt
/
staging
/
ynezz.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
aa239ce
)
base-files: pass "force" parameter to the "sysupgrade" call
author
Rafał Miłecki
<
[email protected]
>
Tue, 3 Sep 2019 12:44:40 +0000
(14:44 +0200)
committer
Jo-Philipp Wich
<
[email protected]
>
Wed, 4 Sep 2019 11:47:17 +0000
(13:47 +0200)
This makes sysupgrade work with the most recent procd that validates
firmware before proceeding.
Signed-off-by: Rafał Miłecki <
[email protected]
>
(cherry picked from commit
b71962da16c2e2b93d633d7bde1436b3da2bf740
)
package/base-files/files/sbin/sysupgrade
patch
|
blob
|
history
diff --git
a/package/base-files/files/sbin/sysupgrade
b/package/base-files/files/sbin/sysupgrade
index 42f0f6bd22e85a62b28a90597ce9bce38b7e8e49..f106c3c981873d1d7628559ee0db173b364e3bc4 100755
(executable)
--- a/
package/base-files/files/sbin/sysupgrade
+++ b/
package/base-files/files/sbin/sysupgrade
@@
-360,9
+360,12
@@
if [ -n "$FAILSAFE" ]; then
printf '%s\x00%s\x00%s' "$RAM_ROOT" "$IMAGE" "$COMMAND" >/tmp/sysupgrade
lock -u /tmp/.failsafe
else
+ force_attr=""
+ [ $FORCE -eq 1 ] && force_attr="\"force\": true,"
ubus call system sysupgrade "{
\"prefix\": $(json_string "$RAM_ROOT"),
\"path\": $(json_string "$IMAGE"),
+ $force_attr
\"command\": $(json_string "$COMMAND"),
\"options\": {
\"save_config\": $SAVE_CONFIG,