I’ve been busy working on the Rundeck scripts, trying to get things worked out and figuring out how to get Rundeck to do what I want.
There is definitely a lot of potential and interesting things that can be done with Rundeck. I really like being able to use curl to trigger jobs but I’m not certain where I want certain steps of the job pipeline handled.
For instance, right now the creation of an OpenStack instance is setup as one job, though it could be broken into an actual instance creation job and a post fixup job.
Right now there is a timing required between those two which requires a 69 second sleep.
Originally I wanted to use curl and trigger the post job from the instance, but I had some issues so I moved the step to the Rundeck job. That’s when I found I needed a sleep.
That sleep is to give vmware tools time to figure out the IP of the instance, but since the instance gets an IP on boot it would be faster to run something on the instance, so I’m back to running a script on boot and having it trigger a job for post updates.
Another thing I’m trying to determine is how I want to use Jenkins. Do I make the Rundeck jobs as minimal as reasonable and build up the chain in Jenkins or do make multistep Rundeck jobs and just trigger them as a higher level Jenkins deploy task, meaning Jenkins wouldn’t know the steps involved in the creation and post fix up of an instance.
Questions, questions, questions…
UPDATE: I separated the post register job from the creation job. Works a lot better now. I still need a sleep, but only 15 seconds in the create job to allow enough time for vcenter to get the MAC address.
I have redone the entire thing to use heat templates. I register rundeck resources from the instances and use FlatDHCP now. So far it works great.