Modify call to multiple_puppetrun

Hi Dominic!!

thanks a lot!!! the tips that you gave me in your last email are really
terrific!!! I successfully managed to extend foreman and foreman-proxy to
use the tags parameter to "run puppet Single Class only" deployment.

I made this by adding a new button (still need to change the icon-play to
something else but this are details), then creating a new function to
deploy a single class only though foreman-proxy.

To successfully finish this, I still need to get the filtered class and
send it to the tag parameter in my new class.

I will continue working on this and I hope I can make it. If I succeed I
will then open source the code, so maybe someone can improve it :-), I am
not a ruby programmer and had to read one book and some tutorials to get
this job done, but I'm really enjoying it.

Ruby rocks!!!

cheers

Anyone knows how could I catch into a variable the class selected on the
filter??
for example when I filter one of my classes and click ok "search":

class = x-server

then I would like something like:

parse(post({:nodes => hosts, :tag => "#{puppetclass.name}"}, "runSingle"))

where puppetclass.name is ideally equal to x-server following up this
example.

Many Thanks!

yes, I made it!! I will open source what I did…perhaps I am not the only
one who wanted this feature in foreman.

Awesome! Sounds like a perfect candidate for a Plugin :wink:

Greg

··· On 14 May 2013 17:22, MrTelebird wrote:

yes, I made it!! I will open source what I did…perhaps I am not the only
one who wanted this feature in foreman.

Thanks!
and here is the code, as promised:


Cheers,
Cesar