source: trunk/web/templates/info.tmpl @ 148

Last change on this file since 148 was 147, checked in by ecprice, 17 years ago

For new naming scheme.

File size: 2.2 KB
Line 
1#from skeleton import skeleton
2#extends skeleton
3
4#def title
5Info on $machine.name
6#end def
7
8
9#def body
10<h1>Info</h1>
11<p>Info on ${machine.name}:</p>
12<table>
13  #for $key, $value in $fields
14  <tr><td>$key:</td><td>$value</td></tr>
15  #end for
16</table>
17
18<p>Commands:</p>
19<form action="command" action="POST">
20  <input type="hidden" name="machine_id" value="$machine.machine_id"/>
21  <table>
22   
23    <tr><td>
24        #if $on
25        #if $has_vnc
26        <a href="vnc?machine_id=$machine.machine_id">Console</a>
27        #else
28        VNC is not enabled
29        #end if
30        #else
31
32        #end if
33    </td></tr>
34      <tr>
35        #if $on
36        <td><input type="submit" class="button" name="action" value="Power off"/></td>
37        <td><input type="submit" class="button" name="action" value="Shutdown"/></td>
38        <td><input type="submit" class="button" name="action" value="Reboot"/></td>
39        #else
40        <td><input type="submit" class="button" name="action" value="Power on"/></td>
41        #end if
42      <td>Boot CD:</td>
43      <td><select name="cdrom">
44          <option selected value="">None</option>
45          #for $cdrom in $cdroms
46          <option value="$cdrom.cdrom_id">
47            $cdrom.description
48          </option>
49          #end for
50      </select></td>
51  </tr>
52    <tr>
53      <td><input type="submit" class="button" name="action" value="Delete VM"/></td>
54    </tr>
55  </table>
56</form>
57<p>Change settings:
58#if $on
59(To edit ram and disk size, turn off the machine first.)
60#end if
61</p>
62<form action="modify" method="POST">
63  <input type="hidden" name="machine_id" value="$machine.machine_id"/>
64  <table>
65    <tr><td>Owner:</td><td><input type="text" value="$machine.owner"/></td></tr>
66    <tr><td>Contact email:</td><td><input type="text" value="$machine.contact"/></td></tr>
67#if $machine.nics
68    <tr><td>Hostname:</td><td><input type="text" value="$machine.nics[0].hostname"/>.servers.csail.mit.edu</td></tr>
69#end if
70#if not $on
71    <tr><td>Ram:</td><td><input type="text" size=3 value="$machine.memory"/>MB (max $max_mem)</td></tr>
72    <tr><td>Disk:</td><td><input type="text" size=3 value="${machine.disks[0].size/1024.}"/>GB (max $max_disk)</td><td>WARNING: Modifying disk size may corrupt your data.</td></tr>
73#end if
74    <tr><td><input type="submit" class="button" name="action" value="Change"/></td></tr>
75  </table>
76</form>
77
78#end def
Note: See TracBrowser for help on using the repository browser.