mirror of
https://github.com/meta-llama/llama-stack.git
synced 2025-06-28 19:04:19 +00:00
35 lines
1.1 KiB
YAML
35 lines
1.1 KiB
YAML
services:
|
|
llamastack:
|
|
image: llamastack/distribution-meta-reference-quantized-gpu
|
|
network_mode: "host"
|
|
volumes:
|
|
- ~/.llama:/root/.llama
|
|
- ./run.yaml:/root/my-run.yaml
|
|
ports:
|
|
- "8321:8321"
|
|
devices:
|
|
- nvidia.com/gpu=all
|
|
environment:
|
|
- CUDA_VISIBLE_DEVICES=0
|
|
command: []
|
|
deploy:
|
|
resources:
|
|
reservations:
|
|
devices:
|
|
- driver: nvidia
|
|
# that's the closest analogue to --gpus; provide
|
|
# an integer amount of devices or 'all'
|
|
count: 1
|
|
# Devices are reserved using a list of capabilities, making
|
|
# capabilities the only required field. A device MUST
|
|
# satisfy all the requested capabilities for a successful
|
|
# reservation.
|
|
capabilities: [gpu]
|
|
runtime: nvidia
|
|
entrypoint: bash -c "python -m llama_stack.distribution.server.server --yaml_config /root/my-run.yaml"
|
|
deploy:
|
|
restart_policy:
|
|
condition: on-failure
|
|
delay: 3s
|
|
max_attempts: 5
|
|
window: 60s
|