Exercise 2d: Standard Input within a Job
For executables requiring standard input, HTCondor provides an option to specify the input file to pipe into the executable.
We can adjust the script.sh script as follows in order to demonstrate this functionality:
#!/bin/bash
for i in {1..3}; do
echo "Enter input $i: "
read input
echo "You have entered: $input"
done
apples
oranges
avocado
executable = script.sh
input = input.txt
output = out.$(ClusterId).$(ProcId)
error = err.$(ClusterId).$(ProcId)
log = log.$(ClusterId).$(ProcId)
queue
Enter input 1:
You have entered: apples
Enter input 2:
You have entered: oranges
Enter input 3:
You have entered: avocado
Last update: November 26, 2019