-
Notifications
You must be signed in to change notification settings - Fork 309
feat: Add cl_devices parameter for mounting host devices to CL containers #1251
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
Conversation
|
Have you validated that it works? As far as I know, this is not yet possible. |
It works only with the needed changes in Kurtosis. I opened even there a PR kurtosis-tech/kurtosis#2845 |
|
you're changing all the imports in your PR to point to your FORK? @dzobbe |
|
Yeah that's right sorry. Let me wait for the PR to get merged first in kurtosis. And once that is done I will fix the imports and test it out. |
|
Could you please also add el_devices/vc_devices to make it uniform across the board? Also please add the new flags into the readme, with a few line of description of what the values do. |
Signed-off-by: Barnabas Busa <[email protected]>
Signed-off-by: Barnabas Busa <[email protected]>
|
@dzobbe you happy with the pr like this ? |
Update
This PR requires you to run the latest (1.14.1+) version of kurtosis!
Summary
This PR adds support for mounting host devices (e.g.,
/dev/tpm0) into Consensus Layer (CL) containers. This enables use cases such as TPM (Trusted Platform Module) access for hardware-backed security features in CL clients like Lighthouse.Changes
Configuration (
network_params.yaml)cl_devices: []parameter to participant structure["/dev/tpm0"])Input Parser (
src/package_io/input_parser.star)cl_devices: []to default participant structurecl_devicesto participant struct creationValidation (
src/package_io/sanity_check.star)cl_devicesto participant validation listsPARTICIPANT_CATEGORIESandPARTICIPANT_MATRIX_PARAMSCL Launchers
Updated all CL client launchers to pass devices to
ServiceConfig:src/cl/lighthouse/lighthouse_launcher.starsrc/cl/lodestar/lodestar_launcher.starsrc/cl/nimbus/nimbus_launcher.starsrc/cl/prysm/prysm_launcher.starsrc/cl/teku/teku_launcher.starsrc/cl/grandine/grandine_launcher.starEach launcher now includes:
if len(participant.cl_devices) > 0:
config_args["devices"] = participant.cl_devices### Package Configuration (
kurtosis.yml)Usage
Users can now specify devices in their
network_params.yaml:aml
participants:
cl_type: lighthouse
cl_devices: ["/dev/tpm0"]
... other configOr for multiple devices:
cl_devices: ["/dev/tpm0", "/dev/tpm1"]
Requirements
This feature requires a patched version of Kurtosis that includes device mounting support in
ServiceConfig. The standard Kurtosis release does not yet support thedevicesfield. A PR has been opened there.Implementation Details
ServiceConfigas a list of stringsTesting
Related
This change enables hardware device access for CL containers, particularly useful for: