Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for an agent drive (ISO) #446

Merged
merged 9 commits into from
Jan 28, 2024
Merged

Add support for an agent drive (ISO) #446

merged 9 commits into from
Jan 28, 2024

Conversation

stgraber
Copy link
Member

With this, a new agent:config disk source can be used to attach a custom ISO to a VM.
This ISO then contains roughly the same data as the normal 9p config drive.

The goal behind this is to provide a way for VMs that don't support 9p but do support virtio-serial and virtio-vsock to still run a functional incus-agent.

Signed-off-by: Stéphane Graber <stgraber@stgraber.org>
Signed-off-by: Stéphane Graber <stgraber@stgraber.org>
Signed-off-by: Stéphane Graber <stgraber@stgraber.org>
Signed-off-by: Stéphane Graber <stgraber@stgraber.org>
Signed-off-by: Stéphane Graber <stgraber@stgraber.org>
Signed-off-by: Stéphane Graber <stgraber@stgraber.org>
Signed-off-by: Stéphane Graber <stgraber@stgraber.org>
Signed-off-by: Stéphane Graber <stgraber@stgraber.org>
@github-actions github-actions bot added Documentation Documentation needs updating API Changes to the REST API labels Jan 28, 2024
@stgraber
Copy link
Member Author

As that extra drive contains sensitive material (TLS keys to talk to the host), the loader is designed to always eject the drive if found. That's combined with us now having logic to actually handle eject requests.

That way, the VM boots, copies the data from the drive and then immediately ejects it so there's no risk of that drive getting accidentally exposed to an unprivileged user down the line.

(The whole thing also requires the user to have manually asked Incus to add such a drive in the first place, so it's pretty much limited to the few Linux distros that don't offer 9p)

Signed-off-by: Stéphane Graber <stgraber@stgraber.org>
@brauner brauner merged commit b11757c into lxc:main Jan 28, 2024
25 checks passed
@stgraber stgraber deleted the agent branch March 20, 2024 10:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
API Changes to the REST API Documentation Documentation needs updating
Development

Successfully merging this pull request may close these issues.

2 participants