agentOS API Reference - v0.2.0-rc.3
    Preparing search index...

    Function nodeModulesMount

    • Mount a host node_modules directory into the VM at /root/node_modules.

      This is the explicit, mount-based replacement for the removed moduleAccessCwd mechanism: the VM module resolver reads the mounted tree through the kernel VFS, so the caller supplies exactly the node_modules directory whose packages should resolve in the guest.

      Parameters

      • hostNodeModulesDir: string

        Absolute host path to a node_modules directory.

      • Optionalopts: { readOnly?: boolean }
        • OptionalreadOnly?: boolean

          Defaults to true; the mount is read-only.

      Returns NodeModulesMountConfig