feat(migration): node key export shared between CLI and devenv - #1318
Open
tt-cll wants to merge 2 commits into
Open
feat(migration): node key export shared between CLI and devenv#1318tt-cll wants to merge 2 commits into
tt-cll wants to merge 2 commits into
Conversation
2 tasks
makramkd
approved these changes
Jul 31, 2026
Comment on lines
+124
to
+136
| passwordPath := filepath.Join(cfg.OutDir, PasswordFileName) | ||
| if err := os.WriteFile(passwordPath, []byte(exportPassword), 0o600); err != nil { | ||
| return nil, fmt.Errorf("failed to write the export password file: %w", err) | ||
| } | ||
|
|
||
| ocr2Path := filepath.Join(cfg.OutDir, OCR2ExportFileName) | ||
| if err := exportToFile(ctx, client.ExportOCR2Bundle, bundleID, exportPassword, ocr2Path); err != nil { | ||
| return nil, fmt.Errorf("failed to export the OCR2 bundle %s: %w", bundleID, err) | ||
| } | ||
| ethPath := filepath.Join(cfg.OutDir, ETHExportFileName) | ||
| if err := exportToFile(ctx, client.ExportETHKey, account, exportPassword, ethPath); err != nil { | ||
| return nil, fmt.Errorf("failed to export the EVM account %s: %w", account, err) | ||
| } |
Collaborator
There was a problem hiding this comment.
In practice, do these files end up being written to the chainlink container? My guess is the paths should point to a volume, so that the operator can get them out?
Contributor
Author
There was a problem hiding this comment.
It writes to a dir which we mount from the host. The runbook should specify the command to run and where the file gets written on disk
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Shared library for the node-facing half of the CL-to-standalone migration: exporting the OCR2 EVM bundle and funded EVM account from a running Chainlink node. Single implementation behind both
ccv migrate export(next PR in the stack) and the devenv cutover (following PR), so the path an operator runs by hand and the path the e2e test exercises cannot drift apart.ccvcommitteeverifierand oneccvexecutorjob); ambiguous bundles/accounts are errors with override options, not guesses.Testing
Unit tests against an httptest fake node that encrypts fixtures with the requested password the way the real node does: bundle/account resolution, job counting, login/cookie flow, export cross-checks, overrides, snippet generation.
Checklist
changelogdirectory)Stack created with GitHub Stacks CLI • Give Feedback 💬