Open eegcl-bugs opened 1 year ago
We want to execute a file (in fact a Bash shell script) when a certain mail arrives, this works already on Suse Linux, but the shell script should also get the mail as an input and be able to process the mail body.
Thank you.
Apart from the obvious problem of synchronisation when reading message contents - at the moment the "Run Program" command only supports transmitting data as command line parameters, this might not be a feasible method for transmitting complete data of an email. Would it help if the mail is saved as "eml" format and then an program could be run that passes the path of the email file as a parameter instead?
This would have an advantage in the implementation as we could execute the saving asynchronously and execute the rest (the command to the bash shell script) once the save is complete.
Yes, it would be fine if the mail would be saved as an eml and then the program would be run with eml-File as a parameter. The Scirpt runs in the following way in the console: ./program.sh mail.eml
Yes, it would be fine if the mail would be saved as an eml and then the program would be run with eml-File as a parameter. The Scirpt runs in the following way in the console: ./program.sh mail.eml
Since the file name has to be unique (and is generated automatically) we will at least need to pass the target folder for the email file as a paramater. based on the example we might include the path as parameter
<program path>,@CONTENT(<storage path>)@
for example:
C:\PROGRAMS\runme.exe,@CONTENT(D:\ProcessedMails)@
This would then generate the file test123.eml (named according to the internal naming conventions of Filtaquilla) and pass the full path on as a parameter to the program like this:
C:\PROGRAMS\runme.exe D:\ProcessedMails\test123.eml
It could use "/" for path if this token was included in the path instead for LInux / Mac based operating systems. FiltaQuilla would make sure the file has been written successfully before issuing the command - the program could then read in the contents from the file location safely.
We want to execute a file (in fact a Bash shell script) when a certain mail arrives, this works already on Suse Linux, but the shell script should also get the mail as an input and be able to process the mail body.
Thank you.