B Tran
B Tran

Reputation: 55

single Rundeck job with 2 scripts running on 2 different nodes

I have a Rundeck job with 2 scripts in it's workflow and can't figure out the ruleset to run each script individually in the job.

My 2 nodes: Server1 and Server2

My 2 scripts are simple and examples are to check if the services are running on the servers. Script1: gsv -name service1 Script2: gsv -name service2

Only Server1 has service1 and should only execute script1 vice versa for Server2 and script2

Right now when the job runs, it will run script1 and script2 on both servers and I'm unable to get the workflow strategy to run only specifically on each. I would like to keep this as one job to verify services on both, eventually scaling to more nodes.

Upvotes: 0

Views: 468

Answers (1)

ambergupta09
ambergupta09

Reputation: 162

You can try something like Job reference step to call multiple existing jobs in a parent job.

Using nodes at step level is not possible. You need to define 2 jobs each calling respective scripts on specific node and use a parent job to finally trigger both the steps.

Upvotes: 1

Related Questions