Command line lxc选项“--&引用;调用lxc start/lxc create时

Command line lxc选项“--&引用;调用lxc start/lxc create时,command-line,containers,lxc,linux-containers,Command Line,Containers,Lxc,Linux Containers,在诸如lxc create或lxc start等命令的命令行中,-的意义是什么 我试图使用谷歌来获得答案,但没有成功 // Example 1 lxc-create -t download -n u1 -- -d ubuntu -r DISTRO-SHORT-CODENAME -a amd64 // Example 1 application="/root/app.out" start="/root/lxc-app/lxc-start" $start -

在诸如
lxc create
lxc start
等命令的命令行中,
-
的意义是什么

我试图使用谷歌来获得答案,但没有成功

// Example 1
lxc-create -t download -n u1 -- -d ubuntu -r DISTRO-SHORT-CODENAME -a amd64

// Example 1
application="/root/app.out"
start="/root/lxc-app/lxc-start"
$start -n LXC_app -d -f /etc/lxc/lxc-app/lxc-app.conf -- $application &

如注释中提供的引用所述,“-”表示传递给命令的选项的结束。以下参数/选项最终将由该命令调用的子命令使用

在您的示例中:

lxc create-t下载-n u1--d ubuntu-r发行版-SHORT-CODENAME-a amd64
lxc create
命令将解释“-t download-n u1”,剩余的“-d ubuntu-r DISTRO-SHORT-CODENAME-a amd64”将传递给模板脚本,模板脚本将配置/填充容器


在这个具体的例子中,“-t download”使
lxc create
运行一个名为“/usr/share/lxc/templates/lxc download”的模板脚本,它将传递到该脚本中“-d ubuntu-r DISTRO-SHORT-CODENAME-a amd64”。

参见示例。谢谢,您的回答已经足够了。