I am trying out the pipe to program feature of the email forwarders.
I began by making a little program in Rust. The program just created a text file at the same folder as the program itself is, and it wrote the parameters you give to it as an argument. I ran the program on my computer
. And it worked perfectly. (I also ran
as explained in the docs. I then put this program in the root folder of the server. In the forwarders section of cPanel I then set up a forwarder and tried sending an email to that email. It did not create a text file. In the "Track delivery" section (don't know if I translated that correctly), I saw a failure, in the result column it said "Child process of jailed_virtual_address_pipe transport returned 1 from command: /usr/local/cpanel/bin/jailexec".
I thought this might have something to do with the fact that I'm creating a text file. So then I made a program that stores the arguments in a firebase realtime database. Again, running it locally worked, but when I put the program on the server and set up the forwarder, I again got the same error.
Does anyone have any experience with this error, or does anyone have any great tutorials or resources on the subject?
In case it can help, here is the program I made that stores the arguments in firebase realtime database (written in Rust).
I began by making a little program in Rust. The program just created a text file at the same folder as the program itself is, and it wrote the parameters you give to it as an argument. I ran the program on my computer
Bash:
./my-program "argument"
Bash:
chmod 0700 my-program
I thought this might have something to do with the fact that I'm creating a text file. So then I made a program that stores the arguments in a firebase realtime database. Again, running it locally worked, but when I put the program on the server and set up the forwarder, I again got the same error.
Does anyone have any experience with this error, or does anyone have any great tutorials or resources on the subject?
In case it can help, here is the program I made that stores the arguments in firebase realtime database (written in Rust).
Code:
extern crate firebase_rs;
use std::env;
fn main() {
println!("Hello, world!");
let args: Vec<String> = env::args().collect();
let mut arg_str: String = String::new();
for arg in args {
arg_str = format!("{} - {}", arg_str, arg)
}
let _firebase = firebase_rs::Firebase::new("https://email-test-76e8c-default-rtdb.europe-west1.firebasedatabase.app/").unwrap();
let users = _firebase.at("data").unwrap();
let _d1 = "{\"response\": \"";
let _d2 = "\"}";
let d = format!("{}{}{}", _d1, arg_str, _d2);
let res = users.set(&d).unwrap();
println!("{:?}", res);
}