Sanity-check tarball before trying to extract

This commit is contained in:
TheSpad 2023-02-05 17:36:01 +00:00
parent 9f56f36d20
commit ebaf781547
No known key found for this signature in database
GPG Key ID: 08F06191F4587860

View File

@ -222,6 +222,10 @@ run_mods() {
"${BLOB_URL}${SHALAYER}" -o \
/modtarball.tar.xz
mkdir -p /tmp/mod
if ! tar -tzf /modtarball.tar.xz >/dev/null 2>&1; then
echo "Invalid tarball, could not download ${DOCKER_MOD}"
continue
fi
tar xzf /modtarball.tar.xz -C /tmp/mod
if [[ -d /tmp/mod/etc/s6-overlay ]]; then
if [[ -d /tmp/mod/etc/cont-init.d ]]; then