Skip to main content

ims orchestration allocation create

Create a new allocation.

Synopsis

The create command allows you to create a new allocation. The command takes a JSON payload (CreateAllocationV0Body) either through a pipe or using the --file flag.

The JSON payload contains:

  • name: the name of the allocation.
  • specification: the specification of the allocation detailing things like the max/min payloads, buffer size, image, the command to run, the ports to expose, etc.

It should be in the following format:

{
"name": "Example Allocation",
"spec": {
"buffer_size": "",
"cluster_id": "",
"expiry_time": "0001-01-01T00:00:00.000Z",
"max_payloads": 0,
"min_payloads": 0,
"payload_spec": {
"command": "",
"args": [],
"environment_variables": [],
"image": "",
"ports": [],
"resources": {
"cpu": "",
"memory": ""
}
}
}
}

For more details on the CreateAllocationV0Body please refer to the OpenAPI specification https://docs.ims.improbable.io/openapi/ims-zeuz/orchestration-api#operation/CreateAllocationV0

ims orchestration allocation create [flags]

Examples

ims orchestration allocation create --project-id alpha-beta-123456 --file ./CreateAllocationV0Body.json
cat ./CreateAllocationV0Body.json | ims orchestration allocation create --project-id alpha-beta-123456

Options

      --file string         path to a json file that contains the CreateAllocationV0Body
-h, --help help for create
--project-id string IMS project id to create the allocation in (required)

Options inherited from parent commands

      --ci                   include this when running in a CI environment, this switches to the IMS service account authentication flow
--config string config file location, defaults to $HOME/.ims
--output-type string command output type (human/json) (default "human")

SEE ALSO