mirror of
https://github.com/meta-llama/llama-stack.git
synced 2025-12-03 09:53:45 +00:00
chore: rename run.yaml to config.yaml
since we only have one config, lets call it config.yaml! this should be treated as the source of truth for starting a stack change all file names, tests, etc. Signed-off-by: Charlie Doern <cdoern@redhat.com>
This commit is contained in:
parent
4a3f9151e3
commit
0cd98c957e
64 changed files with 147 additions and 145 deletions
|
|
@ -35,7 +35,7 @@ For running integration tests, you must provide a few things:
|
|||
- **`server:<config>`** - automatically start a server with the given config (e.g., `server:starter`). This provides one-step testing by auto-starting the server if the port is available, or reusing an existing server if already running.
|
||||
- **`server:<config>:<port>`** - same as above but with a custom port (e.g., `server:starter:8322`)
|
||||
- a URL which points to a Llama Stack distribution server
|
||||
- a distribution name (e.g., `starter`) or a path to a `run.yaml` file
|
||||
- a distribution name (e.g., `starter`) or a path to a `config.yaml` file
|
||||
- a comma-separated list of api=provider pairs, e.g. `inference=fireworks,safety=llama-guard,agents=meta-reference`. This is most useful for testing a single API surface.
|
||||
|
||||
- Any API keys you need to use should be set in the environment, or can be passed in with the --env option.
|
||||
|
|
|
|||
|
|
@ -5,10 +5,10 @@
|
|||
# the root directory of this source tree.
|
||||
|
||||
"""
|
||||
Backward compatibility test for run.yaml files.
|
||||
Backward compatibility test for config.yaml files.
|
||||
|
||||
This test ensures that changes to StackRunConfig don't break
|
||||
existing run.yaml files from previous versions.
|
||||
existing config.yaml files from previous versions.
|
||||
"""
|
||||
|
||||
import os
|
||||
|
|
@ -36,10 +36,10 @@ def get_test_configs():
|
|||
else:
|
||||
# Local mode: test current distribution configs
|
||||
repo_root = Path(__file__).parent.parent.parent
|
||||
config_files = sorted((repo_root / "src" / "llama_stack" / "distributions").glob("*/run.yaml"))
|
||||
config_files = sorted((repo_root / "src" / "llama_stack" / "distributions").glob("*/config.yaml"))
|
||||
|
||||
if not config_files:
|
||||
pytest.skip("No run.yaml files found in distributions/")
|
||||
pytest.skip("No config.yaml files found in distributions/")
|
||||
|
||||
return config_files
|
||||
|
||||
|
|
|
|||
|
|
@ -25,7 +25,7 @@ Here are the most important options:
|
|||
- **`server:<config>`** - automatically start a server with the given config (e.g., `server:starter`). This provides one-step testing by auto-starting the server if the port is available, or reusing an existing server if already running.
|
||||
- **`server:<config>:<port>`** - same as above but with a custom port (e.g., `server:starter:8322`)
|
||||
- a URL which points to a Llama Stack distribution server
|
||||
- a distribution name (e.g., `starter`) or a path to a `run.yaml` file
|
||||
- a distribution name (e.g., `starter`) or a path to a `config.yaml` file
|
||||
- a comma-separated list of api=provider pairs, e.g. `inference=ollama,safety=llama-guard,agents=meta-reference`. This is most useful for testing a single API surface.
|
||||
- `--env`: set environment variables, e.g. --env KEY=value. this is a utility option to set environment variables required by various providers.
|
||||
|
||||
|
|
|
|||
|
|
@ -151,7 +151,7 @@ def pytest_addoption(parser):
|
|||
"""
|
||||
a 'pointer' to the stack. this can be either be:
|
||||
(a) a template name like `starter`, or
|
||||
(b) a path to a run.yaml file, or
|
||||
(b) a path to a config.yaml file, or
|
||||
(c) an adhoc config spec, e.g. `inference=fireworks,safety=llama-guard,agents=meta-reference`, or
|
||||
(d) a server config like `server:ci-tests`, or
|
||||
(e) a docker config like `docker:ci-tests` (builds and runs container)
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@ from llama_stack.core.storage.datatypes import (
|
|||
|
||||
def test_starter_distribution_config_loads_and_resolves():
|
||||
"""Integration: Actual starter config should parse and have correct storage structure."""
|
||||
with open("llama_stack/distributions/starter/run.yaml") as f:
|
||||
with open("llama_stack/distributions/starter/config.yaml") as f:
|
||||
config_dict = yaml.safe_load(f)
|
||||
|
||||
config = StackConfig(**config_dict)
|
||||
|
|
@ -47,7 +47,7 @@ def test_starter_distribution_config_loads_and_resolves():
|
|||
|
||||
def test_postgres_demo_distribution_config_loads():
|
||||
"""Integration: Postgres demo should use Postgres backend for all stores."""
|
||||
with open("llama_stack/distributions/postgres-demo/run.yaml") as f:
|
||||
with open("llama_stack/distributions/postgres-demo/config.yaml") as f:
|
||||
config_dict = yaml.safe_load(f)
|
||||
|
||||
config = StackConfig(**config_dict)
|
||||
|
|
|
|||
|
|
@ -302,7 +302,7 @@ def test_providers_flag_generates_config_with_api_keys():
|
|||
# Read the generated config file
|
||||
from llama_stack.core.utils.config_dirs import DISTRIBS_BASE_DIR
|
||||
|
||||
config_file = DISTRIBS_BASE_DIR / "providers-run" / "run.yaml"
|
||||
config_file = DISTRIBS_BASE_DIR / "providers-run" / "config.yaml"
|
||||
with open(config_file) as f:
|
||||
config_dict = yaml.safe_load(f)
|
||||
|
||||
|
|
|
|||
|
|
@ -32,7 +32,7 @@ def mock_distribs_base_dir(tmp_path):
|
|||
starter_custom = custom_dir / "starter"
|
||||
starter_custom.mkdir()
|
||||
(starter_custom / "starter-build.yaml").write_text("# build config")
|
||||
(starter_custom / "starter-run.yaml").write_text("# run config")
|
||||
(starter_custom / "starter-config.yaml").write_text("# run config")
|
||||
|
||||
return custom_dir
|
||||
|
||||
|
|
@ -48,7 +48,7 @@ def mock_distro_dir(tmp_path):
|
|||
distro_path = distro_dir / distro_name
|
||||
distro_path.mkdir()
|
||||
(distro_path / "build.yaml").write_text("# build config")
|
||||
(distro_path / "run.yaml").write_text("# run config")
|
||||
(distro_path / "config.yaml").write_text("# run config")
|
||||
|
||||
return distro_dir
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue