shell
limactl shell
在 Lima 中执行 shell
概述
在 Lima 中执行 shell
lima 命令是 limactl shell $LIMA_INSTANCE 的别名。$LIMA_INSTANCE 默认为 “default”。
默认情况下,使用在主机 PATH 中找到的第一个 ‘ssh’ 可执行文件连接到 Lima 实例。 可以通过设置 $SSH 环境变量来使用自定义的 ssh 别名。
提示:如果似乎挂起,尝试 –debug 显示详细日志(通常由于 SSH 问题)。
limactl shell [flags] INSTANCE [COMMAND...]
选项
-h, --help help for shell
--reconnect 重新连接到 SSH 会话
--shell string Shell 解释器,例如 /bin/bash
--workdir string 工作目录
从父命令继承的选项
--debug 调试模式
--log-format string 设置日志格式 [text, json] (default "text")
--log-level string 设置日志级别 [trace, debug, info, warn, error]
--tty 启用 TUI 交互,如打开编辑器。默认在终端时为 true。自动化时设为 false。
-y, --yes --tty=false 的别名
另请参见
- limactl - Lima: Linux 虚拟机