Compute

Deploy a Scalix Run service.

Deploys a Scalix Run service and returns the created service.

post/v1/run/services

Request

  • Base URL: https://api.scalix.world
  • URL: https://api.scalix.world/v1/run/services
  • Auth: HTTP bearer

Request body

namestring required

Service name, unique within the project.

image_refstring required

Container image to run.

portinteger nullable

Port the app listens on inside the instance. Default 8080.

envobject nullable

Environment variables.

memory_mbinteger nullable

Memory per instance in MB. Default 256, minimum 128.

vcpusinteger nullable

vCPUs per instance. Default 1.

min_instancesinteger nullable

Minimum instances kept warm. Default 0 (scale to zero).

max_instancesinteger nullable

Maximum instances. Default 10.

target_concurrencyinteger nullable

Concurrent requests per instance before scaling out. Default 50.

scale_down_delay_secsinteger nullable

Idle seconds before scaling in. Default 300.

health_check_pathstring nullable

HTTP path for the readiness probe. Omit for the default check that the app is listening on port.

timeout_secsinteger nullable

Per-request timeout in seconds. Default 300.

rollout_strategystring nullable

instant, health_gated (default), or canary.

volumesobject nullable

Persistent volumes. Attaching one pins the service to a single instance and the instant strategy.

Example request

{
  "name": "api",
  "image_ref": "registry.scalix.world/acme/api:1.4.0",
  "port": 8080,
  "memory_mb": 512,
  "vcpus": 1,
  "max_instances": 10,
  "target_concurrency": 50,
  "scale_down_delay_secs": 300,
  "health_check_path": "/healthz",
  "timeout_secs": 300,
  "rollout_strategy": "health_gated"
}

Response

Service deployed

Changes

No recorded changes to this operation across all 1 revision of this API.