summaryrefslogtreecommitdiff
path: root/meta-google
diff options
context:
space:
mode:
authorWilliam A. Kennington III <wak@google.com>2022-01-27 02:09:11 +0300
committerWilliam A. Kennington III <wak@google.com>2022-01-28 02:09:55 +0300
commitfea3bafb0d02cac60840fe698c9007856d356efa (patch)
tree248e59d81fe2cc3efcd750eaadd18f6d499640cd /meta-google
parent155af451266cd9793f1932c4d16695249948c167 (diff)
downloadopenbmc-fea3bafb0d02cac60840fe698c9007856d356efa.tar.xz
meta-google: gbmc-update: Fix image fetching
The logic was not usable in our current environment. This makes some tweaks to download the image correctly. Change-Id: I86741e6029c2937d0a8106ac22a1738fa0e77cad Signed-off-by: William A. Kennington III <wak@google.com>
Diffstat (limited to 'meta-google')
-rw-r--r--meta-google/recipes-phosphor/flash/gbmc-update/75-gbmc-upgrade.sh7
1 files changed, 4 insertions, 3 deletions
diff --git a/meta-google/recipes-phosphor/flash/gbmc-update/75-gbmc-upgrade.sh b/meta-google/recipes-phosphor/flash/gbmc-update/75-gbmc-upgrade.sh
index c94bf5bd09..fb6bb4d1af 100644
--- a/meta-google/recipes-phosphor/flash/gbmc-update/75-gbmc-upgrade.sh
+++ b/meta-google/recipes-phosphor/flash/gbmc-update/75-gbmc-upgrade.sh
@@ -31,8 +31,9 @@ gbmc_upgrade_hook() {
gbmc_upgrade_fetch() (
echo "Fetching $bootfile_url" >&2
- # We only support tarballs at the moment
- if [[ "$bootfile_url" != *.tar ]]; then
+ # We only support tarballs at the moment, our URLs will always denote
+ # this with a URI query param of `format=TAR`.
+ if ! [[ "$bootfile_url" =~ [\&?]format=TAR(&|$) ]]; then
echo "Unknown upgrade unpack method: $bootfile_url" >&2
return 1
fi
@@ -40,7 +41,7 @@ gbmc_upgrade_fetch() (
# Ensure some sane output file limit
# Currently no BMC image is larger than 64M
ulimit -H -f $((96 * 1024 * 1024)) || return
- wget "$bootfile_url" | tar -xC "$tmpdir" || true
+ wget -q -O - "$bootfile_url" | tar -xC "$tmpdir" || true
local sig
sig="$(find "$tmpdir" -name 'image-*.sig')" || return