llama-stack-mirror/llama_stack/distribution/build_container.sh
Derek Higgins 0de8edd71d feat: switch to Python-based container build system
o Update build.py to call build_container.py instead of shell script
o Maintain build_container.sh for compat

Signed-off-by: Derek Higgins <derekh@redhat.com>
2025-07-24 11:33:15 +01:00

25 lines
703 B
Bash
Executable file

#!/usr/bin/env bash
# Copyright (c) Meta Platforms, Inc. and affiliates.
# All rights reserved.
#
# This source code is licensed under the terms described in the LICENSE file in
# the root directory of this source tree.
# Function to get Python command
get_python_cmd() {
if is_command_available python; then
echo "python"
elif is_command_available python3; then
echo "python3"
else
echo "Error: Neither python nor python3 is installed. Please install Python to continue." >&2
exit 1
fi
}
SCRIPT_DIR=$(dirname "$(readlink -f "$0")")
source "$SCRIPT_DIR/common.sh"
# call the python script
CMD=$(get_python_cmd)
$CMD $SCRIPT_DIR/build_container.py "$@"