WIP: feat: implementation for opnsense os-node_exporter #173

Draft
wjro wants to merge 3 commits from feat/install_opnsense_node_exporter into master
Owner

Added node_exporter to opnsense config and its implementation for OPNSenseFirewall

Added node_exporter to opnsense config and its implementation for OPNSenseFirewall
wjro added 1 commit 2025-10-22 15:29:39 +00:00
feat: implementation for opnsense os-node_exporter
Some checks are pending
Run Check Script / check (pull_request) Waiting to run
8126b233d8
Owner

Could you make a quick screen recording (or screenshot) of this change in action? 📹

Could you make a quick screen recording (or screenshot) of this change in action? 📹
letian reviewed 2025-10-22 15:34:42 +00:00
@ -0,0 +20,4 @@
pub fn get_full_config(&self) -> &Option<NodeExporter> {
&self.opnsense.opnsense.node_exporter
}
fn with_node_exporter<F, R>(&mut self, f: F) -> R
Owner

white line missing

white line missing
wjro marked this conversation as resolved
letian reviewed 2025-10-22 15:34:54 +00:00
@ -0,0 +27,4 @@
match &mut self.opnsense.opnsense.node_exporter.as_mut() {
Some(node_exporter) => f(node_exporter),
None => unimplemented!(
"
Owner

is it expected to have a line return here?

is it expected to have a line return here?
wjro marked this conversation as resolved
Owner

Looking good

Looking good <img src="https://i.giphy.com/FT6DYlscgddh8cTR6d.webp"/>
wjro added 1 commit 2025-10-22 15:51:28 +00:00
fix: removed unimplemnted marco and returned Err instead
Some checks are pending
Run Check Script / check (pull_request) Waiting to run
5af13800b7
some formatting error
wjro added 1 commit 2025-10-22 18:39:20 +00:00
fix: added impl node exporter for hacluster topology and dummy infra
Some checks are pending
Run Check Script / check (pull_request) Waiting to run
5ab58f0253
letian reviewed 2025-10-22 18:55:43 +00:00
@ -0,0 +10,4 @@
}
//TODO complete this impl
impl std::fmt::Debug for dyn NodeExporter {
Owner

I think we should leave it to the implementers to define their Debug impl. So on line 6 we should have pub trait NodeExporter: std::fmt::Debug + Send + Sync instead.

I think we should leave it to the implementers to define their `Debug` impl. So on line 6 we should have `pub trait NodeExporter: std::fmt::Debug + Send + Sync` instead.
Some checks are pending
Run Check Script / check (pull_request) Waiting to run
This pull request is marked as a work in progress.
This branch is out-of-date with the base branch

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin feat/install_opnsense_node_exporter:feat/install_opnsense_node_exporter
git checkout feat/install_opnsense_node_exporter
Sign in to join this conversation.
No reviewers
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: NationTech/harmony#173
No description provided.