status.html 6.98 KB
Newer Older
1
2
3
<div class='row'>
  <div class='col-lg-6  col-lg-offset-3
       col-md-8  col-md-offset-2
4
       col-sm-8  col-sm-offset-2
5
       col-xs-12 col-xs-offset-0'>
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
    <div class='panel panel-default' id='status_panel'>
      <div class="panel-heading">
	<h5>
	  <a data-toggle="collapse" id="profile_status_toggle"
	     href="#profile_status_collapse">
	    <span id='status_message'></span>
	    <span class="glyphicon glyphicon-chevron-right pull-right"></span>
	  </a>
	</h5>
      </div>
      <div id="profile_status_collapse"
	   class="panel-collapse collapse
		  <% if (status_panel_show) { %>in<% } %>">
	<div class='panel-body'>
	  <table class='table table-condensed nospaceafter border-none'>
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
	  <!-- The spinner will start out invisible -->
	  <tr>
	    <td colspan=2 class='border-none'>
	      <div id='status_progress_outerdiv' class='hidden'>
		<div id='status_progress_div'
                     class='progress progress-striped active nospaceafter'>
		  <div class='progress-bar' role='progressbar'
                       id='status_progress_bar'
                       style='width: 33%;'></div>
		</div>
	      </div>
	    </td>
	  </tr>
	  <tr>
	    <td class='border-none'>URN:</td>
	    <td class='border-none'><%- sliceURN %></td>
	  </tr>
	  <tr>
	    <td class='border-none'>State:</td>
	    <td class='border-none'>
              <span id='quickvm_status'>
		<font></font>
              </span>
	    </td>
	  </tr>
46
	  <% if (profileUUID && profileUUID != "") { %>
47
48
	  <tr>
	    <td class='border-none'>Profile:</td>
49
50
51
	    <td class='border-none'>
	      <a target=_blank href='show-profile.php?uuid=<%- profileUUID %>'>
		 <%- profileName %></a></td>
52
	  </tr>
53
	  <% } %>
54
55
	  <tr>
	    <td class='border-none'>Expires:</td>
56
	    <td class='border-none' id='instance_expiration'>
57
58
59
60
              <span id='quickvm_expires'><%- sliceExpiresText %></span>
	      (<span id='quickvm_countdown'></span>)
	    </td>
	  </tr>
61
	  </table>
62
	  <% if (isadmin && publicURL) { %>
63
	  <div class='pull-left'>
64
65
66
67
68
	    <a class='btn btn-info btn-xs pull-left'
               style='margin-right: 10px;'
               href='<%= publicURL %>'
               type='button'>Sliver
	    </a>
69
	  </div>
70
	  <% } %>
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
	  <div class='pull-right'>
	    <% if (registered) { %>
	    <button class='btn btn-xs btn-primary hidden' disabled
		    id='clone_button' type=button>
              Clone</button>
	    <button class='btn btn-xs btn-primary hidden' disabled
		    id='snapshot_button' type=button
		    data-toggle='modal' data-target='#snapshot_modal'>
              Snapshot</button>
	    <% } %>
	    <button class='btn btn-xs btn-success' disabled
		    id='extend_button' type=button>
              Extend</button>
	    <button class='btn btn-xs btn-danger' disabled
		    id='terminate_button' type=button
		    data-toggle='modal' data-target='#terminate_modal'>
              Terminate</button>
	  </div>
89
90
91
92
93
	</div>
      </div>
    </div>
  </div>
</div>
94
95
96
97
98
99
100
101
102
103
104
<!-- Add a hidden div for errors returned by the instantiation. -->
<div class='row hidden' id='error_panel'>
  <div class='col-lg-6  col-lg-offset-3
       col-md-8  col-md-offset-2
       col-sm-8  col-sm-offset-2
       col-xs-12 col-xs-offset-0'>
    <div class="panel panel-danger">
      <div class="panel-heading">
        <center><h4>Error Message</h4></center>
      </div>
      <div class="panel-body">
105
	<code style="white-space: pre-wrap" id="error_panel_text"></code>
106
107
108
109
      </div>
    </div>
  </div>
</div>
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
<!-- Add a div for the instructions if there are instructions. The cliet
     will actually fill in the div though, since it is markdown and that
     is more easily done on the client side for now. -->
<div class='row hidden' id='instructions_panel'>
  <div class='col-lg-6  col-lg-offset-3
       col-md-8  col-md-offset-2
       col-sm-8  col-sm-offset-2
       col-xs-12 col-xs-offset-0'>
    <!-- Collapsable panel -->
    <div class="panel panel-info">
      <div class="panel-heading">
	<h5>
	  <a data-toggle="collapse" href="#instructions">Profile Instructions
	    <span class="glyphicon glyphicon-chevron-right pull-right"></span>
	  </a>
	</h5>
      </div>
      <div id="instructions" class="panel-collapse collapse">
	<div class="panel-body">
	  <div id="instructions_text"></div>
	</div>
      </div>
    </div>
  </div>
</div>
<!-- The topo diagram goes inside this div, when it becomes available. -->
<div class='row'>
  <div class='col-lg-10  col-lg-offset-1
       col-md-10  col-md-offset-1
       col-sm-10  col-sm-offset-1
       col-xs-12 col-xs-offset-0'>
    <div class='panel panel-default invisible' id='showtopo_container'>
      <div class='panel-body'>
	<div id='quicktabs_div'>
	  <ul id='quicktabs' class='nav nav-tabs'>
	    <li class='active'>
              <a href='#profile' data-toggle='tab'>Topology View</a>
            </li>
	    <li>
              <a href='#listview' data-toggle='tab'>List View</a>
            </li>
	    <li>
152
153
              <a href='#manifest' id='show_manifest_tab'
		 data-toggle='tab'>Manifest</a>
154
155
156
157
            </li>
	  </ul>
	  <div id='quicktabs_content' class='tab-content'>
            <div class='tab-pane active' id='profile'>
158
	      <div id='showtopo_statuspage' class='jacks'></div>
159
160
161
162
163
164
165
166
167
168
169
170
171
172
              <small>Click on a node to open a shell on that node. 
                Click and drag to move things around.</small>
	    </div>
            <div class='tab-pane' id='listview'>
	      <div id='showtopo_listview'>
		<table class='table table-striped table-hover table-condensed'
                       id='listview_table'>
                  <thead>
                    <tr>
                      <th>Node</th>
                      <th>Shell (in-browser)</th>
                      <th>SSH command <small>
			  (if you provided your own key)</small>
                      </th>
173
                      <th>Console</th>
174
175
176
177
178
179
180
181
                    </tr>
                  </thead>
                  <tbody>
                  </tbody>
		</table>
              </div>
            </div>
	    <div class='tab-pane' id='manifest'>
182
              <div id='manifest_textarea' style='width: 100%;'></div>
183
184
185
186
187
188
189
190
191
	    </div>
	  </div>
	</div>
      </div>
    </div>
  </div>
</div>
<div>
  <!-- place to hang the modals for now -->
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
  <div id='snapshot_modal' class='modal fade'>
    <div class='modal-dialog'>
      <div class='modal-content'>
	<div class='modal-header'>
          <button type='button' class='close' data-dismiss='modal'
                  aria-hidden='true'>&times;</button>
          <center><h3>Confirm to Snapshot</h3>
	</div>
	<div class='modal-body'>
	  Performing a snapshot will create a new disk image and
	  modify the profile. This is okay, but please confirm.
	  <br>
	  <br>
          <button class='btn btn-danger btn-sm align-center' type='button'
		  id='snapshot_confirm'>Confirm</button></center>
	</div>
      </div>
    </div>
  </div>
211
212
213
214
215
  <div id='waitwait_div'></div>
  <div id='terminate_div'></div>
  <div id='oops_div'></div>
  <div id='register_div'></div>
  <div id='extend_div'></div>
216
  <div id='imaging_div'></div>
217
  <div id='oneonly_div'></div>
218
  <div id='approval_div'></div>
219
</div>