<s> import argh <EOL> from poni import config <EOL> from poni import errors <EOL> INST_AGENT_SH = "<STR_LIT>" <EOL> class PlugIn ( config . PlugIn ) : <EOL> @ argh . arg ( "<STR_LIT>" , "<STR_LIT>" , help = "<STR_LIT>" ) <EOL> def install ( self , arg ) : <EOL> self . log . info ( "<STR_LIT>" , <EOL> self . node . name , self . config . name , arg . verbose , <EOL> arg . extra ) <EOL> if arg . extra : <EOL> print "<STR_LIT>" % arg . extra <EOL> remote = self . node . get_remote ( override = arg . method ) <EOL> exit_code = remote . execute ( INST_AGENT_SH , verbose = arg . verbose ) <EOL> if exit_code : <EOL> raise errors . ControlError ( "<STR_LIT>" % ( <EOL> INST_AGENT_SH , exit_code ) ) <EOL> self . log . info ( "<STR_LIT>" , <EOL> self . node . name , self . config . name ) <EOL> def puppetrun ( self , arg ) : <EOL> remote = self . node . get_remote ( override = arg . method ) <EOL> remote . execute ( "<STR_LIT>" ) <EOL> def add_controls ( self ) : <EOL> self . add_argh_control ( self . install , requires = [ "<STR_LIT>" ] ) <EOL> self . add_argh_control ( self . puppetrun ) <EOL> def add_actions ( self ) : <EOL> self . add_file ( "<STR_LIT>" , mode = <NUM_LIT:0> <NUM_LIT> , <EOL> dest_path = INST_AGENT_SH , render = self . render_cheetah ) </s>
