Skip to Content.
Sympa Menu

en - [sympa-users] Re: Call an external script

Subject: The mailing list for listmasters using Sympa

List archive

Chronological Thread  
  • From: David Verdin <address@concealed>
  • To: Rustam <address@concealed>
  • Cc: address@concealed
  • Subject: [sympa-users] Re: Call an external script
  • Date: Fri, 12 Oct 2007 12:54:36 +0200

Hi,

Rustam a écrit :
I'm trying to setup a list which starts a script upon message arrival
and gets message subject and body as arguments.

As I see the only way to call an external script is to use custom
conditions in authorization scenario. So I've created the following
scenario for my list:

CustomCondition::sendsms([topic],[msg_body]) smtp,smime,md5 -> do_it
true() smtp,smime,md5 -> reject,quiet

But every message gets rejected.
That means that your "verify" function returns always something which is neither '1' nor 'undef'.
If I replace [topic] with
[topic-sender] or [topic-auto] messages come trough
That means your function returns always '1'.
but my script
receives no arguments.
That is probably because the topic wasn't set, neither by the sender nor automatically.

Maybe I use wrong scenario variables ? Can somebody help me, please ?
You control what your code do. If you want to have a more precise view of Sympa behaviour, try running it in debug mode (run sympa.pl daemon with option -d).
Regards,


Best regards,
Rustam.

--
David Verdin
Comité réseau des universités




Archive powered by MHonArc 2.6.19+.

Top of Page