File tree Expand file tree Collapse file tree 1 file changed +13
-11
lines changed
Expand file tree Collapse file tree 1 file changed +13
-11
lines changed Original file line number Diff line number Diff line change @@ -81,17 +81,19 @@ def protocol(environment):
8181 config = environment .configuration ['configuration' ]
8282 context .trigger ('protocol_start' )
8383 context .trigger ('offline' )
84- # start domain
85- logging .info ("Starting the domain" )
86- context .poweron ()
87- # wait until desktop is ready
88- logging .debug ("Waiting %d seconds for desktop to be ready" ,
89- config ['desktop_ready_delay' ])
90- time .sleep (config ['desktop_ready_delay' ])
91- context .trigger ('desktop_ready' )
92- # shutdown
93- logging .info ("Shutting down the domain" )
94- context .poweroff ()
84+ desktop_ready_delay = config ['desktop_ready_delay' ]
85+ if desktop_ready_delay > 0 :
86+ # start domain
87+ logging .info ("Starting the domain" )
88+ context .poweron ()
89+ # wait until desktop is ready
90+ logging .debug ("Waiting %d seconds for desktop to be ready" ,
91+ config ['desktop_ready_delay' ])
92+ time .sleep (config ['desktop_ready_delay' ])
93+ context .trigger ('desktop_ready' )
94+ # shutdown
95+ logging .info ("Shutting down the domain" )
96+ context .poweroff ()
9597 context .trigger ('protocol_end' )
9698
9799
You can’t perform that action at this time.
0 commit comments