Closed sed-i closed 8 months ago
The diff between those two descriptions, 'and start' is key.
The launch
command is basically shorthand for lxc init ubuntu:22.04 u1 < config.yaml && lxc start u1
.
i.e., if you don't want the instance started, just use lxc init
, otherwise use lxc launch
Thanks @holmanb!
Another diff is instance
vs. container
. I imagine it should be instance
in both cases? I guess instance is "container or vm".
Btw, what does --preseed
add to this?
I imagine it should be instance in both cases?
I'm guessing that's just accidentally inconsistent.
Btw, what does --preseed add to this?
I think the docs explain it pretty well - it's intended for providing an instance configuration non-interactively.
Got it! So, iiuc,
lxd init --preseed
takes a LXD daemon config.lxc init
and lxc launch
take a cloud-init.config
in both.Is there a schema doc for the lxd daemon config?
Yes we should update lxc launch and lxc init help text to be consistent, with the only difference being that launch starts the instance after creating it.
@sed-i for future reference support questions are best asked over on the forums
https://discourse.ubuntu.com/c/lxd/126
Thanks!
The description on
launch
andinit
docs is very similar:vs
and in the cloud-init doc it says to use
init
rather thanlaunch
.https://github.com/canonical/lxd/blob/7f0ad17f620f065845b8eda762c692948c22c0b9/doc/cloud-init.md?plain=1#L70
Coming from multipass blueprints, I find this a bit confusing.
I'm also curious about the effect of
--preseed
inlxd init --preseed
and how it compares to the above.