diff --git a/docs/source/distributions/building_distro.md b/docs/source/distributions/building_distro.md index bdc91f6f37..c4833a31a2 100644 --- a/docs/source/distributions/building_distro.md +++ b/docs/source/distributions/building_distro.md @@ -194,7 +194,7 @@ positional arguments: options: -h, --help show this help message and exit - --port PORT Port to run the server on. Defaults to 8321 + --port PORT Port to run the server on. It can also be passed via the env var LLAMA_STACK_PORT. Defaults to 8321 --image-name IMAGE_NAME Name of the image to run. Defaults to the current conda environment --disable-ipv6 Disable IPv6 support diff --git a/llama_stack/cli/stack/run.py b/llama_stack/cli/stack/run.py index 7d6af8120b..e4337b8d02 100644 --- a/llama_stack/cli/stack/run.py +++ b/llama_stack/cli/stack/run.py @@ -37,7 +37,7 @@ def _add_arguments(self): self.parser.add_argument( "--port", type=int, - help="Port to run the server on. Defaults to 8321", + help="Port to run the server on. It can also be passed via the env var LLAMA_STACK_PORT. Defaults to 8321", default=int(os.getenv("LLAMA_STACK_PORT", 8321)), ) self.parser.add_argument(