i'm not a dev, just a user, but in my experience so far, triggers definitely do run on the cobbler server. i have a couple that i use now, one of which is just a simple shell script to iterate through the various locations that cobbler keeps important files (/etc/cobbler, /var/lib/cobbler, and even /usr/lib/python/site-packages/cobbler) and add them to my SVN repo. i also have a more complex python script that maintains selective/arbitrary state info b/w by prod cobbler server and my development cobbler server. and to mark's point i also drop a custom rc.local file onto all provisioned systems to deal with things like vmware tools, custom RHN/Satellite registration and various other junk that i was too lazy to deal with in a more elegant manner (puppet).
i'm not sure if you can, or how you would access cobbler/cheetah variables with a simple shell script, however i can say for sure that my python(xmlrpc) script has access to cobbler variables. i would think that firstboot or rc.local scripts would not have access to these variables, unless they were coded against the api/xmlrpc interface (most likely not a shell script). i'm more than happy to share some or all of these scripts with you, if you think it will help. most likely off list, since i'm not too keen on immortalizing my crappy code on the internet :) good luck, my friend byron -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of [email protected] Sent: Friday, August 13, 2010 4:04 PM To: [email protected]; [email protected] Subject: RE: cobbler/module_loader.py Nope you don't sound like an arse :) I am all for RTFM. However either it's Friday or my brain is fried or..maybe it's just that Python is not my language.. but I don't get it. The documentation to me is very unclear as to what really happens. Do triggers run on the cobbler server? So for instance let's say I have something like this in a trigger: Stupid_trigger.sh #!/bin/bash echo "success $hostname is done" >> /tmp/file (to pick a really silly example). Than when I run something like: wget "http://$server/cblr/svc/op/trig/mode/pre/system/stupid_trigger.sh" -O /dev/null that will run on the cobbler server? Finally if above is true, can trigger gain access to the cobbler/cheetah template variables, or do I have to stand on my head and do rain dance to get variables? (yes it's Friday brain melting...) Marek -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of Byron Pezan Sent: Friday, August 13, 2010 1:56 PM To: cobbler mailing list; [email protected] Subject: RE: cobbler/module_loader.py at the risk of sounding like an ass. get thee to yonder wiki, which is always a good idea before posting: https://fedorahosted.org/cobbler/wiki/CobblerTriggers which inevitably leads to - https://fedorahosted.org/cobbler/wiki/CobblerApi and - https://fedorahosted.org/cobbler/wiki/CobblerXmlrpc byron <flashing back to the old OpenBSD mailing list days /duck :)> -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of [email protected] Sent: Friday, August 13, 2010 3:45 PM To: [email protected]; [email protected] Subject: RE: cobbler/module_loader.py I have to say, I love cobbler thus far, but the documentation seems to me to be impossible to parse effectively. Anyway, do any of you know how I can run a script on the cobbler server after installation? I.E. when installation is finished, I want to run a script on the cobbler server. I can't seem to find a way to do that. Thank you Marek _______________________________________________ cobbler mailing list [email protected] https://fedorahosted.org/mailman/listinfo/cobbler _______________________________________________ cobbler mailing list [email protected] https://fedorahosted.org/mailman/listinfo/cobbler _______________________________________________ cobbler mailing list [email protected] https://fedorahosted.org/mailman/listinfo/cobbler _______________________________________________ cobbler mailing list [email protected] https://fedorahosted.org/mailman/listinfo/cobbler
