Bashscript after successfull send

1 reply [Last post]
SnivleM
User offline. Last seen 26 weeks 4 days ago. Offline
Joined: 2009-07-16

Hello,

I'm having some issues with a simple bashscript that just moves a file after it's been sent successfull.

The bashscript works perfectly when I run it manually, but it won't move the file when the script is triggered by Mendelson AS2.

#!/bin/bash

FN=$1

if [[ -e /home/as2/outbound/$FN ]]; then
mv /home/as2/outbound/$FN /home/as2/outbound/sent/
fi

Obviously $1 is the $filename from the Mendelson AS2 server which gives me the filename.

After some debugging, it appears the script doesn't enter the if, which is strange because it works when I run the script manually.

Are there any environment variables being set by Mendelson AS2 server or something?

Thanks in advance.

SnivleM
User offline. Last seen 26 weeks 4 days ago. Offline
Joined: 2009-07-16

For some strange reason restarting as2 fixed this issue. Before restarting as2 we figured out everything was OK, but the script didn't recognize the as2 user secondary groups.


© 1999-2010 mendelson-e-commerce GmbH | Twitter | Contact us