From b323924c1880d33a66eeafdd0aa43eb99a348571 Mon Sep 17 00:00:00 2001 From: Jamie Land Date: Fri, 21 Feb 2025 10:22:07 -0500 Subject: [PATCH] Updating images so that they are able to run without root access --- llama_stack/distribution/build_container.sh | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/llama_stack/distribution/build_container.sh b/llama_stack/distribution/build_container.sh index 4101cec44..7c6d758c0 100755 --- a/llama_stack/distribution/build_container.sh +++ b/llama_stack/distribution/build_container.sh @@ -177,6 +177,15 @@ ENTRYPOINT ["python", "-m", "llama_stack.distribution.server.server"] EOF fi +# Add other require item commands genearic to all containers +add_to_container << EOF + +# Allows running as non-root user +RUN mkdir -p /.llama /.cache + +RUN chmod -R g+rw /app /.llama /.cache +EOF + printf "Containerfile created successfully in $TEMP_DIR/Containerfile\n\n" cat $TEMP_DIR/Containerfile printf "\n"