Skip to Content
Homemade
Dashboard

Apply services live

PUT
/api/vms/{vmId}/services

Changes the services of a running computer now, without updating the project: send the whole .homemade/config.jsonc text as config (or the services map). New and changed services start, removed ones stop, unchanged ones keep running, and their links follow. Only services take effect; other changed keys are listed in needsImageUpdate. Answers each service's health.

Authorization

apiKey
headerAuthorizationBearer <hmk_…>

An API key from the dashboard or homemade api-key create.

Path Parameters

vmId*string

Request Body

application/json
  1. body
config?string

The whole .homemade/config.jsonc text. Only its services take effect now.

Lengthlength <= 262144
restart?array<>

Services to start again even when they did not change.

Itemsitems <= 64
services?

The new services, in the config's services shape, instead of config.

Response Body

What changed, and each service's health.

application/json
  1. response
failed*array<string>

Services that failed.

ready*boolean

Every service that starts by itself is healthy.

services*array<>
applied*
needsImageUpdate*array<string>

Config keys besides services that differ from the project's ready setup; they take effect after its next update.

warnings*array<string>
Example Request
curl -X PUT 'https://api.homemade.dev/api/vms/string/services' \  -H 'Content-Type: application/json' \  -d '{}'
Example Response
{  "failed": [    "string"  ],  "ready": true,  "services": [    {      "exitCode": -9007199254740991,      "log": [        "string"      ],      "name": "string",      "port": 1,      "state": "starting",      "url": "string"    }  ],  "applied": {    "kept": [      "string"    ],    "started": [      "string"    ],    "stopped": [      "string"    ]  },  "needsImageUpdate": [    "string"  ],  "warnings": [    "string"  ]}