orbstack_machine_pull
Transfer files from Linux virtual machines to macOS using OrbStack. Specify source path, optional destination, and machine name to copy files between systems.
Instructions
从 Linux 机器拉取文件到 macOS。
Args: params: 包含源文件路径、可选的目标路径和机器名
Returns: str: 传输结果
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| params | Yes |
Implementation Reference
- src/orbstack_mcp/server.py:620-640 (handler)The implementation of the orbstack_machine_pull tool handler.
async def orbstack_machine_pull(params: MachineFileTransferInput) -> str: """从 Linux 机器拉取文件到 macOS。 Args: params: 包含源文件路径、可选的目标路径和机器名 Returns: str: 传输结果 """ args = ["pull"] if params.machine: args.extend(["-m", params.machine]) args.append(params.source) if params.destination: args.append(params.destination) code, stdout, stderr = await _run_orb(args) if code != 0: return _format_error(stderr) return f"文件已拉取: {params.source}" + (f" -> {params.destination}" if params.destination else "") - src/orbstack_mcp/server.py:610-618 (registration)Registration of the orbstack_machine_pull tool.
@mcp.tool( name="orbstack_machine_pull", annotations={ "title": "从 Linux 机器拉取文件", "readOnlyHint": False, "destructiveHint": False, "idempotentHint": False, "openWorldHint": False, }, - src/orbstack_mcp/server.py:143-155 (schema)Schema definition for MachineFileTransferInput.
class MachineFileTransferInput(BaseModel): """文件传输的输入参数""" model_config = ConfigDict(str_strip_whitespace=True, extra="forbid") source: str = Field( ..., description="源文件路径", min_length=1, ) destination: Optional[str] = Field( default=None, description="目标路径,不指定则使用当前目录", )