X-Git-Url: http://xvm.mit.edu/gitweb/invirt/packages/invirt-web.git/blobdiff_plain/d3e746ad10f7dc4e54cfd382b4825e77b2916186..93de0c02b63e2eb954a00d4e8b481b5df0560dfb:/code/templates/info.mako?ds=sidebyside

diff --git a/code/templates/info.mako b/code/templates/info.mako
index 9628e70..1fb4284 100644
--- a/code/templates/info.mako
+++ b/code/templates/info.mako
@@ -5,18 +5,24 @@
 Info on ${machine.name}
 </%def>
 
+%if os.path.exists("/etc/invirt/motd.html"):
+<div class="result">
+<p class="error">${open('/etc/invirt/motd.html').read()|n}</p>
+</div>
+%endif
+
 <%def name="infoTable()">
 <h2>Info</h2>
 <table>
   % for key, value in fields:
   <tr><td>${key}:</td><td>${value}</td></tr>
   % endfor
+  % if on:
+   % if 'monitoring' in config and len(config.monitoring) and 'baseuri' in config.monitoring[0]:
+    <tr><td>CPU history:</td><td><img src="${config.monitoring[0].baseuri}usage.cgi?type=cpu;uuid=${machine.uuid}" alt="Domain CPU usage" /></td></tr>
+   % endif
+  % endif
 </table>
-% if on:
- % if 'monitoring' in config and len(config.monitoring) and 'baseuri' in config.monitoring[0]:
-  <img src="${config.monitoring[0].baseuri}usage.cgi?type=cpu;uuid=${machine.uuid}" alt="Domain CPU usage" />
- % endif
-% endif
 </%def>
 
 <%def name="commands()">
@@ -50,7 +56,7 @@ Info on ${machine.name}
 	% endif
   </div>
   <div>
-	${command_button("Delete VM", "delete", extra='''onclick="return confirm('Are you sure that you want to delete this VM?');"''')}
+  ${command_button("Delete VM", "delete", extra='''onclick="return confirm('Are you sure that you want to delete this VM (\\\'%s\\\')?');"''' % (machine.name))}
   </div>
 </%def>