Advanced
Customize the VM
Configure the agentOS VM that builds and serves each app.
With Core, use the vm option to configure the
agentOS VM that serves each app:
const dynamicApps = createDynamicApps({
// Release hooks omitted.
vm: {
software: [firstPackage, secondPackage],
onAgentStderr: (event) => logger.error(event),
onLimitWarning: (warning) => logger.warn(warning),
},
});
Dynamic Apps itself controls where the app’s code is placed in the VM and the
V8 heap limit. vm options cannot override them.
Use the separate logger option for application output and build events.
The VM itself is configured through agentOS:
- Software: packages available inside the VM
- Resource Limits: CPU, memory, and disk caps
- Permissions: filesystem, process, and network boundaries