vLLM over HTTP
FROM vllm/vllm-openai:latestRUN curl -fsSL https://surfra.io/install.sh | shENTRYPOINT ["surfra", "worker"]import surfra
surfra.App("qwen").deploy( image="ghcr.io/you/vllm-surfra:1", entrypoint="vllm serve Qwen/Qwen3-0.6B --host 127.0.0.1 --port 8000", runtime={ "engine": "http", "port": 8000, "path": "/v1/chat/completions", "ready_path": "/health", "ready_timeout": 1800, }, autoscale={ "max_replicas": 3, "idle_timeout_sec": 600, "execution_timeout_sec": 600, "providers": [ {"provider": "salad", "gpu": "rtx4090", "priority": 1}, {"provider": "runpod", "gpu": "rtx4090", "priority": 2}, ], },)import osfrom openai import OpenAI
client = OpenAI(base_url="https://api.surfra.io/openai/qwen/v1", api_key=os.environ["SURFRA_API_KEY"])reply = client.chat.completions.create( model="Qwen/Qwen3-0.6B", messages=[{"role": "user", "content": "Say hi"}],)print(reply.choices[0].message.content)The first call waits for the image pull and model download. Raise ready_timeout for larger models. The same pattern works for SGLang, TGI, and Ollama. See HTTP servers.
