Skip to main content
Announcements
SYSTEM MAINTENANCE: Thurs., Sept. 19, 1 AM ET, Platform will be unavailable for approx. 60 minutes.
cancel
Showing results for 
Search instead for 
Did you mean: 
anselmopeixoto
Partner - Creator III
Partner - Creator III

Calling multiple shell scripts from tSystem

Hello community,

How can I call multiple shell scripts (Linux) from a single tSystem component? Has anyone here done it before that could provide some insights?

As stated on the community knowledge article "Can I execute multiple commands at one time with a tSystem component?" the following example works:

touch file1.txt ; touch file2.txt

But trying to call multiple shell scripts using the same approach, doesn't. Example:

/opt/talend/script1.sh ; /opt/talend/script2.sh

or even the following, considering the "/opt/talend" directory is already set at tSystem's "Home directory" parameter:

./script1.sh ; ./script2.sh

As a result of previous example, only the first script is actually called. This can be reproduced creating two simple scripts like following:

# ! /usr/bin/bash

echo "TEST 1"

# ! /usr/bin/bash

echo "TEST 2"

I know I could do it by using multiple tSystem components or even by calling one script from another and them call only the first from tSystem, but the idea is to create a dynamic list of scripts.

Thanks in advance.

Best regards,

Anselmo

Labels (2)
0 Replies