-
Notifications
You must be signed in to change notification settings - Fork 3
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
Change watchdog to a single binary #10
Conversation
Using [geckodriver](https://hg.mozilla.org/mozilla-central/file/tip/testing/geckodriver) as a refernce, this commit changes the code into a monolith binary. Imports are much easier to understand now.
This adds a new dependency `error-chain`. This package helps in easy error chaining and handling. Traceback is so easy now. Also removing the logger in the coming patches because pam_exec gives a simpler logging facility. No need of writing code for logging in rust.
src/init.rs
Outdated
panic!("Watchdog: Couldn't open log file"); | ||
} | ||
}; | ||
// pub fn init_logger(config: &Config) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why are these commented out?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I should delete them. Logging will be done directly from pam_exec
itself.
Cargo.toml
Outdated
|
||
[lib] | ||
name = "common_lib" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use lib instead of common_lib
Requesting reviews @fristonio @vrongmeal