feat(nvlink-manager): don't read desired cert from the filesystem when deciding whether NVswitch cert rotation is required.#3975
Conversation
..from the filesystem when deciding whether NVswitch cert rotation is required. Instead, just check the expiry of the cert presented by the switch; if it expires within a configured timeframe, trigger cert rotation via the rack state machine. Signed-off-by: Thomas McRoberts <tmcroberts@nvidia.com>
|
@coderabbitai review |
✅ Action performedReview finished.
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Enterprise Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (5)
💤 Files with no reviewable changes (1)
Summary by CodeRabbit
WalkthroughNMX-C certificate rotation now uses certificate expiry windows instead of desired-certificate mismatches. Configuration, monitoring metrics, maintenance decisions, compatibility aliases, and integration tests were updated accordingly. ChangesNMX-C certificate rotation
Estimated code review effort: 4 (Complex) | ~45 minutes Sequence Diagram(s)sequenceDiagram
participant NvLinkConfig
participant SwitchCertificateMonitor
participant NMXCEndpoint
participant RackMaintenance
participant OpenTelemetry
NvLinkConfig->>SwitchCertificateMonitor: provide rotate_before_expiry
SwitchCertificateMonitor->>NMXCEndpoint: probe certificate
NMXCEndpoint-->>SwitchCertificateMonitor: return observed certificate
SwitchCertificateMonitor->>SwitchCertificateMonitor: evaluate cert_expires_within
SwitchCertificateMonitor->>RackMaintenance: request maintenance when rotation_required
SwitchCertificateMonitor->>OpenTelemetry: report rotation-window status
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
Description
Currently, the switch monitor reads a cert from a configured file location, and compares its fingerprint with the fingerprint of the cert presented by the switch. If there's a mismatch, the monitor triggers a cert rotation.
Instead, just check the expiry of the cert presented by the switch; if it expires within a configured timeframe, trigger cert rotation via the rack state machine. This means NICo does not need the secret to be mounted in its filesystem.
Related issues
#2327
Type of Change
Breaking Changes
Testing
Additional Notes