run_request.html.ep 5.03 KB
Newer Older
1
2
<!DOCTYPE html>
<html ng-app="ravada.app">
serk's avatar
serk committed
3
4
5
<script>
    $_anonymous=<%= ($_anonymous or 0) %>;
</script>
6
7
8
9
10
%= include 'bootstrap/header'
<body role="document">
    %= include 'bootstrap/navigation'
    <div class="container theme-showcase" role="main"
        ng-controller="run_domain_req"
Francesc Guasch's avatar
Francesc Guasch committed
11
        ng-init="id_request=<%= $request->id %>;auto_view=<%= $auto_view %>;timeout=<%= $timeout %>"
12
    >
13
    <div class="jumbotron" ng-cloak="">
14

Fernando Verdugo's avatar
Fernando Verdugo committed
15
        <h2><%=l 'Running' %> {{domain.name}}</h2>
16
17

            <div class="alert alert-warning">
Fernando Verdugo's avatar
Fernando Verdugo committed
18
                <%=l 'A viewer is required to run the virtual machines.' %>
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
                <a href="/requirements"><%=l 'Read more.' %></a>
            </div>
        <div ng-hide="request.status == 'done'">Waiting for machine to start {{dots}}</div>
        <div ng-show="domain">
            <div ng-show="domain.description ||(domain.is_active && domain.msg_timeout)">
                <span ng-bind-html="domain.description"
                        ng-show="domain.description">{{domain.description}}
                </span>
                <span ng-show="domain.msg_timeout && domain.is_active">
                         <hr ng-show="domain.description">
                         <%=l 'This machine will shut down' %>
                         {{domain.msg_timeout}}
                </span>
            </div>
            <div "panel-body" ng-show="domain.is_active">
34
            <h3>Connection</h3>
35
36
37
38
39
40
41
42
43
            <ul ng-show="domain.is_active">
                <li ng-show="domain.spice_password">
                    <%=l 'The password for this virtual machine connection is :'%>
                    <input
                            ng-model="password"
                            ng-click="copy_password()"
                            type="text" class="js-copytextarea"
                                        value="{{domain.spice_password}}"
                    />
44
                    <i ng-show="password_clipboard"><%=l 'copied to clipboard' %></i>
45
46
47
48
49
50
                </li>

                <li><b>Display URL :</b>
                    <a ng-click="copy_password(); redirect()"
                        href="{{domain.display_url}}">{{domain.display_url}}</a></li>
                </li>
51
                <li><b>Display IP :</b> {{domain.display.ip}} </li>
Francesc Guasch's avatar
Francesc Guasch committed
52
                <li><b>Display Port :</b> {{domain.display.port}} </li>
53
            </ul>
54
55
56
57
58
59
60
61
62
            <h3>Machine Information</h3>
            <ul>
                <li><b>Internal IP:</b><span ng-show="domain.ip"> {{domain.ip}}</span>
                    <span ng-hide="domain.ip"><i>waiting for network to come up</i></span>
                </li>
                <li><b>Max Memory:</b> {{domain.max_mem}}</li>
                <li><b>Memory:</b> {{domain.memory}}</li>
                <li><b>CPUs:</b> {{domain.nrVirtCpu}}</li>
            </ul>
63
64
            <h3 ng-show="domain.ports.length">Open ports</h3>
            <ul ng-show="domain.ports.length">
Francesc Guasch's avatar
Francesc Guasch committed
65
66
                <li ng-repeat="port in domain.ports">
                    <b>{{port.name}}</b>
67
                    {{domain.display.ip}}:{{port.public_port}}
Francesc Guasch's avatar
Francesc Guasch committed
68
69
70
71
                    <i class="fa fa-arrow-right"></i>
                    {{port.internal_port}}
                </li>
            </ul>
72
73
            </div>
            <div ng-show="domain.is_active">
Francesc Guasch's avatar
Francesc Guasch committed
74
                <div>
75
                <a type="button" class="btn btn-success"
Francesc Guasch's avatar
Francesc Guasch committed
76
                    ng-show="!domain.display.tls_port"
77
                    ng-click="view_clicked=true; copy_password(); redirect();"
78
                    href="/machine/display/{{domain.id}}.vv">
79
                        <b><%=l 'view'%></b></a>
Francesc Guasch's avatar
Francesc Guasch committed
80
81
82
83
84
85
86
87

                <a type="button" class="btn btn-success" ng-view="domain,display.tls_port"
                    ng-show="domain.display.tls_port"
                    ng-click="view_clicked_tls=true; copy_password(); redirect();"
                    href="/machine/display-tls/{{domain.id}}-tls.vv">
                        <b><%=l 'view'%></b></a>
                </div>
                <div>
88
                <span ng-show="view_clicked"><%=l 'If you can not see the machine screen in a few seconds check for a file called' %> <b>{{domain.id}}.vv</b> <%=l 'in your downloads folder.' %>
89
                </span>
Francesc Guasch's avatar
Francesc Guasch committed
90
91
92
93
94
                <span ng-show="view_clicked_tls"><%=l 'If you can not see the machine screen in a few seconds check for a file called' %> <b>{{domain.id}}-tls.vv</b> <%=l 'in your downloads folder.' %>
                </span>
                <br/>
                <i><%=l 'Press SHIFT + F12 to exit the virtual machine' %></i>
                </div>
95
            </div>
Francesc Guasch's avatar
Francesc Guasch committed
96
97
98
99
        </div>
        <div>
            <div class="panel-body">
                <div ng-show="request.error && !domain.is_active">{{request.error}}</div>
Fernando Verdugo's avatar
Fernando Verdugo committed
100
                <div ng-show="domain && request.status == 'done' && domain.is_active == 0"><%=l 'The machine is down.'%>
Fernando Verdugo's avatar
Fernando Verdugo committed
101
                 <button type="submit" class="btn btn-primary" onclick="location.reload('forceGet')"><%=l 'Start again'%></button>
Francesc Guasch's avatar
Francesc Guasch committed
102
                </div>
103
104
105
106
107
108
109
110
111
112
            </div>

        </div>


    </div>
</div>
    %= include 'bootstrap/scripts'
</body>
</html>