From 9ce0da661b336e09bd94c1b0b1e360fd17d9e219 Mon Sep 17 00:00:00 2001 From: bit-aloo Date: Thu, 12 Dec 2024 11:57:58 +0530 Subject: [PATCH] add unix specific execution permission to tp binary executable --- roles/tests-integration/tests/common/mod.rs | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/roles/tests-integration/tests/common/mod.rs b/roles/tests-integration/tests/common/mod.rs index a0e061afa9..a816c9ef91 100644 --- a/roles/tests-integration/tests/common/mod.rs +++ b/roles/tests-integration/tests/common/mod.rs @@ -126,8 +126,17 @@ impl TemplateProvider { unpack_tarball(&tarball_bytes, &temp_dir); + let bitcoind_binary = bitcoin_exe_home.join("bitcoind"); + + #[cfg(unix)] + { + use std::os::unix::fs::PermissionsExt; + let mut perms = std::fs::metadata(&bitcoind_binary).unwrap().permissions(); + perms.set_mode(0o755); + std::fs::set_permissions(&bitcoind_binary, perms).unwrap(); + } + if os == "macos" { - let bitcoind_binary = bitcoin_exe_home.join("bitcoind"); std::process::Command::new("codesign") .arg("--sign") .arg("-")