mirror of
https://github.com/kata-containers/kata-containers.git
synced 2026-07-28 10:26:16 +00:00
shellcheck: restore build-base-qemu.sh directives
An earlier commit in this PR accidentally removed the shellcheck
source directives, CROSS_BUILD initializer, repo_root_dir fallback,
and nounset-safe ${1:-} defaults, causing the "Shellcheck required"
CI check to fail.
Restore the file to match the main-branch state for these lines.
Signed-off-by: Zvonko Kaiser <zkaiser@nvidia.com>
Assisted-by: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -8,12 +8,19 @@ set -o errexit
|
||||
set -o nounset
|
||||
set -o pipefail
|
||||
|
||||
CROSS_BUILD="${CROSS_BUILD:-false}"
|
||||
|
||||
script_dir="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
readonly qemu_builder="${script_dir}/build-qemu.sh"
|
||||
|
||||
# shellcheck source=/dev/null
|
||||
source "${script_dir}/../../scripts/lib.sh"
|
||||
# shellcheck source=/dev/null
|
||||
source "${script_dir}/../qemu.blacklist"
|
||||
|
||||
# Ensure repo_root_dir is available
|
||||
repo_root_dir="${repo_root_dir:-$(git rev-parse --show-toplevel 2>/dev/null || echo "${script_dir}/../../../..")}"
|
||||
|
||||
ARCH=${ARCH:-$(uname -m)}
|
||||
|
||||
packaging_dir="${script_dir}/../.."
|
||||
@@ -21,8 +28,8 @@ qemu_destdir="/tmp/qemu-static/"
|
||||
container_engine="${USE_PODMAN:+podman}"
|
||||
container_engine="${container_engine:-docker}"
|
||||
|
||||
qemu_repo="${qemu_repo:-$1}"
|
||||
qemu_version="${qemu_version:-$2}"
|
||||
qemu_repo="${qemu_repo:-${1:-}}"
|
||||
qemu_version="${qemu_version:-${2:-}}"
|
||||
build_suffix="${3:-}"
|
||||
qemu_tar="${4:-}"
|
||||
|
||||
@@ -42,7 +49,7 @@ CACHE_TIMEOUT=$(date +"%Y-%m-%d")
|
||||
|
||||
container_image="${QEMU_CONTAINER_BUILDER:-$(get_qemu_image_name)}"
|
||||
|
||||
${container_engine} pull "${container_image}" || ("${container_engine}" build \
|
||||
"${container_engine}" pull "${container_image}" || ("${container_engine}" build \
|
||||
--build-arg CACHE_TIMEOUT="${CACHE_TIMEOUT}" \
|
||||
--build-arg http_proxy="${http_proxy}" \
|
||||
--build-arg https_proxy="${https_proxy}" \
|
||||
|
||||
Reference in New Issue
Block a user