> condor_status -constraint 'SlotID==1' -format '+TargetSlot = "%s"\nqueue\n\n' Name >> runit.sub {endcode} + +-- + +If you are ok with different clusters for each job - + +{code} +$ cat do_cmd.sub +cmd = da_cmd +requirements = TARGET.SlotId == 1 && TARGET.Machine == "$(machine)" +queue +$ for m in $(condor_status -master); do condor_submit -a machine=$m do_cmd.sub; done +{endcode} + +If you want it in a single cluster - + +{code} +#!/bin/sh + +cmd=$1; shift +args=$@ + +( + echo "cmd = $cmd" + echo "args = $args" + echo "requirements = TARGET.SlotId == 1 && TARGET.Machine == My.TargetMachine" + for machine in $(condor_status -master); do + echo "+TargetMachine = \"$machine\"" + echo "queue" + done +) | condor_submit +{endcode}