These are the docs for 13.6, an old version of SpatialOS. The docs for this version are frozen: we do not correct, update or republish them. 14.5 is the newest →

Configuring a deployment to be launched

This file contains the configuration parameters for starting a deployment. You can specify it in the [launch_configuration] field of a project configuration or pass it to spatial alpha local launch or spatial alpha cloud launch via the --launch_config flag.

Configuration file

The file may be called by any name but should have the following structure:

  "template": "...",
  "dimensionsInWorldUnits": {
    "x": 100,
    "z": 100
  "loadBalancing": {
    "layerConfigurations": [
        "layer": "...",
        "hexGrid": {
          "numWorkers": ...
  "snapshot": {
    "takeSnapshotIntervalSeconds": "600",
    "startDeploymentFromSnapshotFile": "snapshots/default.snapshot"
  "streamingQueryInterval": 4,
  "runtimeFlags": [
      "name": "...",
      "value": "..."
Field Required/Optional Description
template Required Defines the compute resources your deployment needs (its ‘topology’). See deployment templates for more details.
dimensionsInWorldUnits Required Describes how big the world should be. “x” and “z” parameters must both be greater than 0.
loadBalancing Optional The new load balancing configuration as documented in load balancing with layers.
snapshot Optional Defines snapshot related settings. It contains two optional fields:
- takeSnapshotIntervalSeconds: The frequency in seconds to automatically write snapshots of your simulated world. The minimum duration is 600 seconds (10 minutes). Set to 0 to disable automatic snapshots. Default value is 0.
- startDeploymentFromSnapshotFile: A relative (to the location of this file) or absolute path to the default snapshot file to start deployments with. You can overwrite the snapshot to use with the --snapshot flag when starting a deployment with the spatial CLI.
streamingQueryInterval Optional Period in seconds between successive streaming query updates. The default value is 4 seconds.
runtimeFlags Optional The Runtime flags that can control advanced runtime features. Equivalent to legacy flags.

Search results

Was this page helpful?

Thanks for letting us know!

Thanks for your feedback

Need more help? Ask on the forums