llama distribution -> llama stack + containers (WIP)

This commit is contained in:
Ashwin Bharambe 2024-08-28 10:07:08 -07:00
parent 45987996c4
commit fd3b65b718
16 changed files with 204 additions and 80 deletions

View file

@ -8,4 +8,35 @@
set -euo pipefail
podman run -it -p 8001:8001 -v ~/.llama/test.yaml:/app/test.yaml test-image --yaml_config /app/test.yaml --disable-ipv6
RED='\033[0;31m'
NC='\033[0m' # No Color
error_handler() {
echo "Error occurred in script at line: ${1}" >&2
exit 1
}
trap 'error_handler ${LINENO}' ERR
if [ $# -lt 3 ]; then
echo "Usage: $0 <docker_image> <yaml_config> <port> <other_args...>"
exit 1
fi
docker_image="$1"
shift
yaml_config="$1"
shift
port="$1"
shift
set -x
podman run -it \
-p $port:$port \
-v "$yaml_config:/app/config.yaml" \
$docker_image \
python -m llama_toolchain.distribution.server \
--yaml_config /app/config.yaml \
--port $port "$@"