DeployConfig and its nested models define exactly what a deployment does.
Quick Start
1
API config
2
Cloud config
DeployConfig
Validation rules:
type="cloud"requires acloud:section, otherwise raisesValueError("cloud config required for cloud deployment type").type="api"fills inAPIConfig()defaults when omitted.type="docker"fills inDockerConfig()defaults when omitted.
Enums
DeployType
CloudProvider
"aws" · "azure" · "gcp" · "fly" · "railway" · "render"
This enum names the built-ins only — it is not the list of deployable providers. An enum can’t be extended at runtime, so the authority is
praisonai_deploy.providers.list_cloud_providers(). Validate a name with coerce_cloud_provider(), and add your own targets via Custom cloud providers.CloudProviderLike
CloudProviderLike = Union[CloudProvider, str]
The accepted type for provider. Built-ins keep their enum identity on the way out (config.provider is CloudProvider.AWS); plugin providers come back as normalised lowercase strings.
ServiceState
running · stopped · pending · failed · not_found · unknown
APIConfig
DockerConfig
Sibling api: block (Docker only)
type: docker accepts an optional sibling api: block that configures the API server the container will run. Fields are the same as APIConfig above.
Omitting the block runs the container with the same defaults as
type: api — auth on, CORS on, port 8005.
Generated Gunicorn CMD
type: docker generates a Dockerfile whose CMD starts Gunicorn with fixed worker-timeout values tuned for agent LLM workloads.
These values are hard-coded in
praisonai_deploy/docker.py (constant DEFAULT_GUNICORN_TIMEOUT). There is no YAML knob for them yet — if you need a different worker timeout, generate the Dockerfile with praisonai deploy plan and edit the CMD line before building.The sibling
api: block is type: docker-only. On type: cloud it is dropped — cloud providers shell out to external CLIs and never generate the API server.CloudConfig
The
provider value is normalised (.strip().lower()) before validation, so AWS, aws, and " aws " all resolve to CloudProvider.AWS. Unknown names raise ValueError: Invalid cloud provider: X. Must be one of: …, where the list comes from the registry (built-ins plus any installed plugins).AgentConfig
Best Practices
Let defaults fill themselves in
Let defaults fill themselves in
For
type="api" and type="docker", omit the nested block to accept sensible defaults. Only add fields you need to change.Always set cloud fields explicitly
Always set cloud fields explicitly
provider, region, and service_name are required for cloud deployments and have no defaults.Quote cpu and memory values
Quote cpu and memory values
cpu and memory are strings ("256", "512"), not integers — quote them in YAML.Related
Python API
Deploy class and result models
Quick Start
Minimal agents.yaml per type
Custom Providers
Register your own cloud target

