: if ( !$post.addpost ) { : if ( $post.unreachable ) {

<: $post.title :>

Could not reach this hypervisor: <: $post.state :>
: } else {

<: $post.title :> <: $post.state :> : if ( $post.is_self ) { dom0 : } : if ( !$post.has_recipe ) { unprovisioned : } : # Nothing waits on the process which reprovisions, so its own : # status file is the only account of it there is. : if ( $post.reprovision_state ) { <: $post.reprovision_status :> : }

: # Declared private in the sidecar, so a reader who cannot edit : # never receives it -- there is nothing here to remember to guard. : if ( $post.preview ) { console of <: $post.title :>
: } on <: $post.hypervisor_title :> — <: $post.vcpus :> vCPU : if ( $can_edit && $post.recipe ) {
Recipe — <: $post.recipe_path :>
<: $post.recipe :>
: } : if ( $can_edit && $post.reprovision_log ) {
Last reprovision — <: $post.reprovision_status :> : if ( $post.reprovision_exit ) { (exit <: $post.reprovision_exit :>) : }
<: $post.reprovision_log :>
: if ( $post.reprovision_log_href ) { Read the whole log : }
: } : if ( $can_edit ) {
: # Trog::DataSource::Virt::act() refuses these for the : # server drawing the page. Not offering them is not the guard. : # (A semicolon in a Kolon comment ends the statement, so do not.) : if ( !$post.is_self ) { : if ( $post.is_active ) { : } else { : } : } : if ( !$post.is_self ) { : }
: # Separate form, because this one carries a passphrase and has : # no business sharing a submit with the buttons above. : # can_reprovision is false while one is running, so this is : # the only thing drawn for a guest mid-provision. : if ( $post.is_reprovisioning ) {

Reprovisioning now : if ( $post.reprovision_by ) { — started by <: $post.reprovision_by :> : } : if ( $post.reprovision_log_href ) { — watch the log : }

: } : if ( $post.can_reprovision ) {
: # The passphrase is asked for in the popover rather than : # sat in the page, so nothing is typed until Reprovision is : # pressed, and the confirmation is a button you have to hit : # rather than a confirm() nobody reads. The popover stays : # inside the form, so the passphrase is submitted with it. : # popovertarget as well as the command attributes, since a : # browser which has popover but not invoker commands would : # otherwise have no way to open this at all. Where both are : # understood the command wins and the target is ignored, so : # they do not fight. : # A browser old enough to have neither draws this inline and : # submits it, which is the form this replaced, minus the : # confirmation.

Reprovision <: $post.title :>? This destroys the guest and builds it again from its recipe. Anything on it the recipe does not describe will not come back.

: # Either the passphrase, or a code standing in for the : # passphrase they already stored. See _passphrase() in : # ProvisionedVirt: a code is proof they are here, and is : # exchanged for the stored one rather than being any part : # of it. : if ( $post.passphrase_remembered ) { : } else { : } : # Asked for separately, and only when there is not one : # stored: sudo on the hypervisor has no terminal to ask : # at, so a run that needs it and was not given it dies : # minutes in. Empty is the ordinary answer, since the : # login there usually has passwordless sudo. : if ( !$post.sudo_remembered ) { : } : if ( $post.can_remember && ( !$post.passphrase_remembered || !$post.sudo_remembered ) ) { : }
: } : }
: } : }