* Added a power off button to managing the Striker.

* Added a reboot button to managing the Striker. This button and the text associated with it reflects the need for the reboot.

Signed-off-by: Digimer <digimer@alteeve.ca>
main
Digimer 6 years ago
parent 18455ab5f7
commit c3a26c32f0
  1. 11
      cgi-bin/striker
  2. BIN
      html/skins/alteeve/images/reboot_icon.png
  3. BIN
      html/skins/alteeve/images/reboot_needed_icon.png
  4. 19
      html/skins/alteeve/striker.html
  5. 5
      share/words.xml

@ -236,10 +236,17 @@ sub process_task
}
else
{
# What we show for the reboot icon and text depends on if a reboot is pending.
my $reboot_needed = $anvil->System->reboot_needed();
my $reboot_icon = $reboot_needed ? "reboot_needed_icon.png" : "reboot_icon.png";
my $reboot_message = $reboot_needed ? "#!string!striker_0093!#" : "#!string!striker_0092!#";
# The 'back' goes home
$anvil->data->{form}{back_link} = "?";
my $reset_icon =
$anvil->data->{form}{body} = $anvil->Template->get({file => "striker.html", name => "striker-setup"});
$anvil->data->{form}{body} = $anvil->Template->get({file => "striker.html", name => "striker-setup", variables => {
reboot_icon => $reboot_icon,
reboot_message => $reboot_message,
}});
}
}
elsif (0)

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

@ -259,15 +259,28 @@
</tr>
<tr>
<td rowspan="2" class="icon_button">
<a href="?striker=true&task=reset"><img src="#!data!skin::url!#/images/#!variable!reset_icon!#" class="top_icon" ></a>
<a href="?striker=true&task=reboot"><img src="#!data!skin::url!#/images/#!variable!reboot_icon!#" class="top_icon" ></a>
</td>
<td class="menu_title">
<a href="?striker=true&task=reset">#!string!striker_0091!#</a>
<a href="?striker=true&task=reboot">#!string!striker_0091!#</a>
</td>
</tr>
<tr>
<td class="menu_details">
#!variable!reset_message!#
#!variable!reboot_message!#
</td>
</tr>
<tr>
<td rowspan="2" class="icon_button">
<a href="?striker=true&task=poweroff"><img src="#!data!skin::url!#/images/power_icon.png" class="top_icon" ></a>
</td>
<td class="menu_title">
<a href="?striker=true&task=poweroff">#!string!striker_0094!#</a>
</td>
</tr>
<tr>
<td class="menu_details">
#!string!striker_0095!#
</td>
</tr>
</table>

@ -77,7 +77,6 @@ Report maintenance mode: #!variable!program!#
</key>
<key name="message_0046">This system is in maintenance mode.</key>
<key name="message_0047">This system is NOT in maintenance mode.</key>
<key name="message_0048">This system has been set to need a reboot.</key>
<key name="message_0049">This system was already set to need a reboot, nothing changed.</key>
<key name="message_0050">This system has has been set to no longer need a reboot.</key>
@ -453,9 +452,11 @@ Here we will inject 't_0006', which injects 't_0001' which has a variable: [#!st
<key name="striker_0088">The system will be updated momentarily. This system will now be in maintenance mode until the update is complete.</key>
<key name="striker_0089">This indicates whether this system needs to be rebooted or not.</key>
<key name="striker_0090">This system is in maintenance mode and is not currently available.</key>
<key name="striker_0091">Reset this Striker</key>
<key name="striker_0091">Reboot this Striker</key>
<key name="striker_0092">This option will restart the host operating system. This is not currently needed.</key>
<key name="striker_0093">This machine needs to be rebooted. This option will restart the host operating system.</key>
<key name="striker_0094">Power off this Striker</key>
<key name="striker_0095">This will power off the Striker machine and leave it off. To power it back on, you will need physical access or cycle the power of the PDU feeding this Striker.</key>
<!-- Strings used by jobs -->
<key name="job_0001">Configure Network</key>

Loading…
Cancel
Save