Ñò –­PSc @ssddkiZddkZddkZddkZddklZddkl Z l Z de fd„ƒYZ dS(iÿÿÿÿN(t DebugValues(tIMG_USERt IMG_ENTIREtActuatorcBs3eZdZeddddddgƒZhheƒd6eƒd6eƒd6eiiiei i fgd6eƒd6eƒd6d6heƒd6eƒd6eƒd6eiiiei i fgd6eƒd6eƒd6d6heƒd6eƒd6eƒd6eiiiei i fgd6eƒd6eƒd6d 6Z d „Z e d"d „ƒZe d"d „ƒZe d"d „ƒZd„Zd„Zed„ƒZd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Z d„Z!d„Z"d„Z#d„Z$d „Z%d!„Z&RS(#s[Actuators are action attributes that cause side effects on live images when those actions are updated, installed or removed. Since no side effects are caused when the affected image isn't the current root image, the OS may need to cause the equivalent effect during boot. This is Solaris specific for now. s reboot-neededs release-notet refresh_fmrit restart_fmrit suspend_fmrit disable_fmritinstalltremovaltupdatecCs^h|_h|_h|_d|_d|_t|_d|_d|_ t |_ d|_ dS(Nti( RR R tNonet suspend_fmristtmp_suspend_fmristTruet do_nothingtcmd_patht sync_timeouttFalset act_timed_outtzone(tself((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pyt__init__Rs         cCs%tiiti|itid|ƒS(sReturns the serialized state of this object in a format that that can be easily stored using JSON, pickle, etc.tje_state(tpkgtmisct json_encodeRt__name__t__dict__t_Actuator__state__desc(tobjR((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pytgetstate^scCsDt|ƒi}tii||tid|ƒ}|ii|ƒdS(sjUpdate the state of this object using previously serialized state obtained via getstate().tjd_stateN( ttypeRRRt json_decodeRRRR (RtstateR!tname((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pytsetstateescCs tƒ}ti|||ƒ|S(s`Allocate a new object using previously serialized state obtained via getstate().(RR&(R$R!trv((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pyt fromstatets cCs ||_dS(s8 Set actuator timeout. 'timeout' Actuator timeout in seconds. The following special values are allowed: 0: don't use synchronous actuators -1: no timeout, wait until finished N(R(Rttimeout((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pyt set_timeout|scCs ||_dS(sƒSpecify if actuators are supposed to be run within a zone. If 'zname' is None, actuators are run in the global zone, otherwise actuators are run in the zone 'zname'. The caller has to make sure the zone exists and is running. If there are any issues with calling an actuator in the zone, it will be ignored.N(R(Rtzname((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pytset_zone…scCs|iS(N(R(R((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pyt timed_outscCs|ip|ip|iS(N(RR R (R((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pyt__bool__“scCs!t|ip|ip|iƒS(N(tboolRR R (R((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pyt __nonzero__–scCs#|i|i|i|iiƒdS(N(t_Actuator__scanRtdsttptdestination_fmri(Rtap((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pyt scan_installšscCs#|i|i|i|iiƒdS(N(R1R tsrcR3t origin_fmri(RR5((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pyt scan_removalscCsP|io#|i|i|i|iiƒn|i|i|i|iiƒdS(N(R7R1R R3R4R2(RR5((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pyt scan_update s #cCs»|i}x«t|iƒƒ|i@D]}|djoG||}t|tƒp |g}n|i|tƒƒi|ƒq#|idjo&|i|tƒƒi ||fƒq#q#WdS(Ns release-notetfile( tattrstsettkeystactuator_attrst isinstancetlistt setdefaultR R%tappend(Rt dictionarytacttfmriR<tatvalues((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pyt__scan¥s     cCsíd„}h}xn|i|i|igD]T}xK|iƒD]=}x4|||ƒD]"}|i|tƒƒi|ƒqRWq;Wq(W|iƒotdgƒ|dRBR=taddt reboot_needed(RRMtmergetdRGtsmft_[1]RF((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pytget_list²s  (  cCs&|iidgƒ|iidgƒS(s2Returns a list of tuples of possible release notess release-note(R tgetR(R((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pytget_release_note_infoËscCsBg}|iƒD]*\}}|djo|||fqq~S(s2Returns a list of services that would be restartedRJRN(struesfalse(RU(RRTRFRS((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pytget_services_listÐscCsdid„|iƒDƒƒS(Ns css)x"|]\}}d||fVqWdS(s %16s: %sN((t.0RFRS((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pys Ös (tjoinRU(R((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pyt__str__Õs cCstd|iidgƒjƒS(sNReturns True if action install execution may require a reboot.RJs reboot-needed(R/RRV(R((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pytreboot_advisedÙscCsAtd|iidgƒjƒptd|iidgƒjƒS(sQReturns True if action execution requires a new boot environment.RJs reboot-needed(R/R RVR (R((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pyRPßs"cOsŽ|io|i|d|iƒD]0}ti |d|iƒo|i |ƒqüqüW||_||_t||Bƒ}|o|iti|dtƒnt|ƒ}|o|iti|ƒndS(s'do pre execution actuator processing...NRRRt temporary(RR RVR=R RSt check_fmrisRtcopyt get_statetSMF_SVC_TMP_ENABLEDtremoveROt is_disabledR Rttuplet_Actuator__invoketdisableR(RRtR Rt disable_fmrisRFR$tparams((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pytexec_pre_actuatorss8         cCsJ|iodSt|i|iBƒ}|o|itid|ƒndS(shandle a failed installNt maintenance(RR}R RR~RStmark(RRtR((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pytexec_fail_actuators<s    cCsÁ|iodSx/|iiƒD]}t|ƒo |ƒqqWx/|iiƒD]}t|ƒo |ƒqQqQWx/|iiƒD]}t|ƒo |ƒqƒqƒW|iidtƒƒ|iidtƒƒB|iidtƒƒB}|iidtƒƒ|iidtƒƒB|iidtƒƒB}ti d|d|i ƒ}ti d|d|i ƒ}x>|i ƒD]0}ti |d|i ƒo|i |ƒqpqpWt|ƒ}|o |iti|d|iƒnx>|i ƒD]0}ti |d|i ƒo|i |ƒqäqäWt|ƒ}|o |iti|d|iƒnt|iƒ}|o |iti|d|iƒnt|iƒ}|o&|iti|dtd|iƒndS(s%do post execution actuator processingNRRRRRv(RR t itervaluesRKRR RVR=RSRwRRxR|R{R}R~trefreshRtrestartR tenableRR(RRtREt refresh_fmrist restart_fmrisRFR((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pytexec_post_actuatorsHsV    ++         N('Rt __module__t__doc__R=R?RtactionstgenerictNSGRFtPkgFmriRRt staticmethodR R R&R(R*R,tpropertyR-R.R0R6R9R:R1RURWRXR[R\RPR~RuR‚R…RŒ(((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pyR%sr                             * ( tpkg.smfRSt pkg.actionsRRjtpkg.misctpkg.client.debugvaluesRtpkg.client.imagetypesRRtobjectR(((s9/usr/lib/python2.6/vendor-packages/pkg/client/actuator.pyts