Index With Counter
BIN
static/counter/0.gif
Normal file
After Width: | Height: | Size: 10 KiB |
BIN
static/counter/1.gif
Normal file
After Width: | Height: | Size: 6.5 KiB |
BIN
static/counter/2.gif
Normal file
After Width: | Height: | Size: 6.9 KiB |
BIN
static/counter/3.gif
Normal file
After Width: | Height: | Size: 11 KiB |
BIN
static/counter/4.gif
Normal file
After Width: | Height: | Size: 9.7 KiB |
BIN
static/counter/5.gif
Normal file
After Width: | Height: | Size: 9.3 KiB |
BIN
static/counter/6.gif
Normal file
After Width: | Height: | Size: 8.3 KiB |
BIN
static/counter/7.gif
Normal file
After Width: | Height: | Size: 8.1 KiB |
BIN
static/counter/8.gif
Normal file
After Width: | Height: | Size: 1.3 KiB |
BIN
static/counter/9.gif
Normal file
After Width: | Height: | Size: 5 KiB |
30
static/style/style.css
Normal file
|
@ -0,0 +1,30 @@
|
|||
* {
|
||||
background-color: black;
|
||||
color: white;
|
||||
}
|
||||
|
||||
|
||||
.counter {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.counter-image {
|
||||
image-rendering: pixelated;
|
||||
image-rendering: -moz-crisp-edges;
|
||||
image-rendering: crisp-edges;
|
||||
flex-grow: 200;
|
||||
}
|
||||
|
||||
.worker table{
|
||||
border: 1px solid white;
|
||||
border-collapse: collapse;
|
||||
border-spacing: 5px;
|
||||
}
|
||||
|
||||
.worker td{
|
||||
border: 1px solid white;
|
||||
}
|
||||
|
||||
.worker tr{
|
||||
border: 1px solid white;
|
||||
}
|
83
tmpl/index.tmpl
Normal file
|
@ -0,0 +1,83 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<link rel="stylesheet" href="/static/style/style.css">
|
||||
</head>
|
||||
<body>
|
||||
<h1>Morffix</h1>
|
||||
|
||||
<div id="wierd-flex" class="counter">
|
||||
{{range $c := .Counter}}
|
||||
<img class="counter-image" alt="{{$c}}" src="/static/counter/{{$c}}.gif">
|
||||
{{end}}
|
||||
</div>
|
||||
|
||||
<div class="worker-list">
|
||||
{{range $w := .Workers}}
|
||||
<div class="worker">
|
||||
<h4>{{ $w.Name }}</h4>
|
||||
<table>
|
||||
<tr>
|
||||
<td>
|
||||
Address
|
||||
</td>
|
||||
<td>
|
||||
{{ $w.Address }}
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
Connected
|
||||
</td>
|
||||
<td>
|
||||
{{ $w.Connected }}
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
ConnectionChanged
|
||||
</td>
|
||||
<td>
|
||||
{{ $w.ConnectionChanged }}
|
||||
</td>
|
||||
</tr>
|
||||
{{if $w.Connected}}
|
||||
<tr>
|
||||
<td>
|
||||
CPUs
|
||||
</td>
|
||||
<td>
|
||||
{{ $w.Status.CPUCount }}
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
CPU Usage
|
||||
</td>
|
||||
<td>
|
||||
{{ $w.Status.CPUUsage }}%
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
Memory
|
||||
</td>
|
||||
<td>
|
||||
{{ $w.Status.MemoryTotal }} GB
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
Memory Usage
|
||||
</td>
|
||||
<td>
|
||||
{{ $w.Status.MemoryUsage }}%
|
||||
</td>
|
||||
</tr>
|
||||
{{end}}
|
||||
</table>
|
||||
</div>
|
||||
{{end}}
|
||||
</div>
|
||||
</body>
|
||||
</html>
|