Skip to content

Commit

Permalink
Merge pull request #621 from bytedance/fix-patchdir
Browse files Browse the repository at this point in the history
fix patch dir cannot found
  • Loading branch information
yoloyyh authored May 23, 2024
2 parents 5613934 + ce0bdac commit 6f60543
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions rasp/librasp/src/manager.rs
Original file line number Diff line number Diff line change
Expand Up @@ -531,12 +531,14 @@ impl RASPManager {
) -> AnyhowResult<()> {
info!("create rasp runtime path: {}", rasp_runtime_path);
// dose Agent create `agent_runtime_path`?
if !Path::new(agent_runtime_path).exists() {
return Err(anyhow!(
"can not found agent runtime path: {}",
agent_runtime_path
));
}
// /var/run/elkeid-agent cannot find who create, so just create the dir
// if !Path::new(agent_runtime_path).exists() {

// return Err(anyhow!(
// "can not found agent runtime path: {}",
// agent_runtime_path
// ));
// }
let rasp_runtime_path_full = format!("{}{}", agent_runtime_path, rasp_runtime_path);
let path = Path::new(&rasp_runtime_path_full);
if path.exists() {
Expand Down

0 comments on commit 6f60543

Please sign in to comment.