1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
{% extends "layout.html" %}
{% block title %}Instance inspection{% endblock %}
{% block head %}
{{ super() }}
<link href="{{ url_for('static', filename='css/jqueryFileTree.css', _external=False) }}" rel="stylesheet" type="text/css" media="screen" />
<script src="{{ url_for('static', filename='js/jquery/jqueryFileTree.js') }}" type="text/javascript" charset="utf-8"></script>
<link href="{{ url_for('static', filename='css/jqueryTabs.css', _external=False) }}" rel="stylesheet" type="text/css" media="screen" />
<script src="{{ url_for('static', filename='js/jquery/jqueryTabs.js') }}" type="text/javascript" charset="utf-8"></script>
<script src="{{ url_for('static', filename='js/ace/ace-uncompressed.js') }}" type="text/javascript" charset="utf-8"></script>
<script src="{{ url_for('static', filename='js/ace/theme-crimson_editor.js') }}" type="text/javascript" charset="utf-8"></script>
<link href="{{ url_for('static', filename='css/colorbox.css', _external=False) }}" rel="stylesheet" type="text/css" media="screen" />
<script src="{{ url_for('static', filename='js/jquery/jquery.colorbox-min.js') }}" type="text/javascript" charset="utf-8"></script>
<script src="{{ url_for('static', filename='js/scripts/inspectInstance.js') }}" type="text/javascript" charset="utf-8"></script>
{% endblock %}
{% block body %}
<input type='hidden' name='root' id='root' value='{%if file_path != "" %}{{file_path}}{%endif%}' />
<h2>Instance inspection</h2><br/>
<div id="tabContaier">
<ul>
<li><a class="active" href="#tab1">Parameters</a></li>
<li><a href="#tab2">Slapgrid Supervisor</a></li>
<li><a href="#tab3">SLAP response</a></li>
<li><a href="#tab4">Partitions Content</a></li>
</ul><!-- //Tab buttons -->
<div class="tabDetails">
<div id="tab1" class="tabContents">
<p>Add your instance parameters here and click on the update button</p>
<textarea class="parameter" id="parameter"></textarea>
<input type="submit" name="update" id ="update" value="Update" class="button"/>
</div><!-- end tab1 -->
<div id="tab2" class="tabContents">
<p>This tab show all process generated by slapgrid for your application. You can click on the process name to display log.</p>
{% if supervisor != []%}
<table cellpadding="0" cellspacing="0" width="100%">
<tr>
<th>Partition and Process name</th><th>Status</th><th>Process PID </th><th> UpTime</th><th></th>
</tr>
{% for item in supervisor %}
<tr>
<td><b><a href="{{ url_for('tailProcess', process=item[0]) }}">{{ item[0]}}</a></b></td>
<td align="center"><a href="{{ url_for('startStopProccess', process=item[0], action=item[1]) }}">{{ item[1]}}</a></td>
<td align="center">{{ item[3]}}</td><td>{{ item[5]}}</td>
<td align="center"><a href="{{ url_for('startStopProccess', process=item[0], action='RESTART') }}">Restart</a></td>
</tr>
{% endfor %}
</table>
{% else %}
<h2>No process to display, please run your instance</h2>
{%endif%}
</div><!-- end tab2 -->
<div id="tab3" class="tabContents">
<p>Uses parameters below to run your application</p>
<table cellpadding="0" cellspacing="0" width="100%">
{% for item in slap_status %}
<tr>
<th align='left' colspan='2'>Computer Partition {{ item[0]}}</th>
</tr>
{% for k in item[1] %}
<tr>
<td>{{k}}</td><td align='left'>{{item[1][k]}}</td>
</tr>
{% endfor %}
{% endfor %}
</table>
</div><!-- end tab3 -->
<div id="tab4" class="tabContents">
<div id="fileTree" class="file_tree_tabs"></div>
</div><!-- end tab4 -->
</div>
</div>
<!-- This contains the hidden content for inline calls -->
<a class='inline' style='display:none' href="#inline_content">Inline HTML</a>
<div style='display:none'>
<div id='inline_content' style='padding:10px; background:#fff;'>
</div>
</div>
{% endblock %}