dStats 1.0.0__tar.gz → 1.0.1__tar.gz
Sign up to get free protection for your applications and to get access to all the features.
- dstats-1.0.1/MANIFEST.in +4 -0
- {dstats-1.0.0 → dstats-1.0.1}/PKG-INFO +1 -1
- dstats-1.0.1/dStats/templates/dStats/index.html +189 -0
- {dstats-1.0.0 → dstats-1.0.1}/dStats.egg-info/PKG-INFO +1 -1
- {dstats-1.0.0 → dstats-1.0.1}/dStats.egg-info/SOURCES.txt +3 -1
- {dstats-1.0.0 → dstats-1.0.1}/setup.py +1 -1
- {dstats-1.0.0 → dstats-1.0.1}/LICENSE +0 -0
- {dstats-1.0.0 → dstats-1.0.1}/README.md +0 -0
- {dstats-1.0.0 → dstats-1.0.1}/dStats/__init__.py +0 -0
- {dstats-1.0.0 → dstats-1.0.1}/dStats/asgi.py +0 -0
- {dstats-1.0.0 → dstats-1.0.1}/dStats/server.py +0 -0
- {dstats-1.0.0 → dstats-1.0.1}/dStats/settings.py +0 -0
- {dstats-1.0.0 → dstats-1.0.1}/dStats/urls.py +0 -0
- {dstats-1.0.0 → dstats-1.0.1}/dStats/views.py +0 -0
- {dstats-1.0.0 → dstats-1.0.1}/dStats/wsgi.py +0 -0
- {dstats-1.0.0 → dstats-1.0.1}/dStats.egg-info/dependency_links.txt +0 -0
- {dstats-1.0.0 → dstats-1.0.1}/dStats.egg-info/entry_points.txt +0 -0
- {dstats-1.0.0 → dstats-1.0.1}/dStats.egg-info/requires.txt +0 -0
- {dstats-1.0.0 → dstats-1.0.1}/dStats.egg-info/top_level.txt +0 -0
- {dstats-1.0.0 → dstats-1.0.1}/setup.cfg +0 -0
dstats-1.0.1/MANIFEST.in
ADDED
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.2
|
2
2
|
Name: dStats
|
3
|
-
Version: 1.0.
|
3
|
+
Version: 1.0.1
|
4
4
|
Summary: A real-time web-based monitoring tool that provides performance stats for Docker containers and visualizes their network connectivity graph
|
5
5
|
Home-page: https://github.com/Arifcse21/dStats
|
6
6
|
Author: Abdullah Al Arif
|
@@ -0,0 +1,189 @@
|
|
1
|
+
<!DOCTYPE html>
|
2
|
+
<html>
|
3
|
+
<head>
|
4
|
+
<title>Docker Stats</title>
|
5
|
+
<script src="https://code.jquery.com/jquery-3.6.0.min.js"></script>
|
6
|
+
<style>
|
7
|
+
body {
|
8
|
+
font-family: Arial, sans-serif;
|
9
|
+
margin: 0;
|
10
|
+
padding: 20px;
|
11
|
+
background-color: #f5f5f5;
|
12
|
+
}
|
13
|
+
|
14
|
+
.container {
|
15
|
+
display: flex;
|
16
|
+
gap: 20px;
|
17
|
+
}
|
18
|
+
|
19
|
+
.stats-panel, .graph-panel {
|
20
|
+
flex: 1;
|
21
|
+
background: white;
|
22
|
+
padding: 20px;
|
23
|
+
border-radius: 8px;
|
24
|
+
box-shadow: 0 2px 4px rgba(0,0,0,0.1);
|
25
|
+
}
|
26
|
+
|
27
|
+
table {
|
28
|
+
width: 100%;
|
29
|
+
border-collapse: collapse;
|
30
|
+
}
|
31
|
+
|
32
|
+
th, td {
|
33
|
+
padding: 12px;
|
34
|
+
text-align: left;
|
35
|
+
border-bottom: 1px solid #ddd;
|
36
|
+
}
|
37
|
+
|
38
|
+
th {
|
39
|
+
background-color: #f8f9fa;
|
40
|
+
font-weight: bold;
|
41
|
+
}
|
42
|
+
|
43
|
+
tr:hover {
|
44
|
+
background-color: #f5f5f5;
|
45
|
+
}
|
46
|
+
|
47
|
+
.graph-image {
|
48
|
+
width: 100%;
|
49
|
+
height: auto;
|
50
|
+
}
|
51
|
+
|
52
|
+
.button-group {
|
53
|
+
margin-bottom: 20px;
|
54
|
+
}
|
55
|
+
|
56
|
+
.button-group button {
|
57
|
+
padding: 10px 20px;
|
58
|
+
margin-right: 10px;
|
59
|
+
border: none;
|
60
|
+
border-radius: 5px;
|
61
|
+
background-color: #007bff;
|
62
|
+
color: white;
|
63
|
+
cursor: pointer;
|
64
|
+
}
|
65
|
+
|
66
|
+
.button-group button:hover {
|
67
|
+
background-color: #0056b3;
|
68
|
+
}
|
69
|
+
</style>
|
70
|
+
</head>
|
71
|
+
<body>
|
72
|
+
<div class="button-group">
|
73
|
+
<button id="showStats">Show Stats Only</button>
|
74
|
+
<button id="showGraph">Show Graph Only</button>
|
75
|
+
<button id="showBoth">Show Both</button>
|
76
|
+
</div>
|
77
|
+
|
78
|
+
<div class="container">
|
79
|
+
<div class="stats-panel" id="statsPanel">
|
80
|
+
<h2>Container Stats</h2>
|
81
|
+
<table id="statsTable">
|
82
|
+
<thead>
|
83
|
+
<tr>
|
84
|
+
<th>Container Name</th>
|
85
|
+
<th>CPU Usage</th>
|
86
|
+
<th>Memory Usage</th>
|
87
|
+
<th>Network I/O</th>
|
88
|
+
</tr>
|
89
|
+
</thead>
|
90
|
+
<tbody>
|
91
|
+
</tbody>
|
92
|
+
</table>
|
93
|
+
</div>
|
94
|
+
|
95
|
+
<div class="graph-panel" id="graphPanel">
|
96
|
+
<h2>Network Visualization</h2>
|
97
|
+
<img id="networkGraph" class="graph-image" src="" alt="Docker Network Graph">
|
98
|
+
</div>
|
99
|
+
</div>
|
100
|
+
|
101
|
+
<script>
|
102
|
+
let updateStatsInterval = null;
|
103
|
+
let updateGraphInterval = null;
|
104
|
+
|
105
|
+
function updateStats() {
|
106
|
+
$.get('{% url "stats" %}', { type: 'stats' })
|
107
|
+
.done(function(data) {
|
108
|
+
const tbody = $('#statsTable tbody');
|
109
|
+
tbody.empty();
|
110
|
+
|
111
|
+
data.stats.forEach(function(container) {
|
112
|
+
tbody.append(`
|
113
|
+
<tr>
|
114
|
+
<td>${container.name}</td>
|
115
|
+
<td>${container.cpu_percent}</td>
|
116
|
+
<td>${container.memory_usage}</td>
|
117
|
+
<td>${container.network_io}</td>
|
118
|
+
</tr>
|
119
|
+
`);
|
120
|
+
});
|
121
|
+
})
|
122
|
+
.fail(function(error) {
|
123
|
+
console.error('Error fetching stats:', error);
|
124
|
+
});
|
125
|
+
}
|
126
|
+
|
127
|
+
function updateGraph() {
|
128
|
+
$.get('{% url "stats" %}', { type: 'graph' })
|
129
|
+
.done(function(data) {
|
130
|
+
$('#networkGraph').attr('src', 'data:image/png;base64,' + data.graph);
|
131
|
+
})
|
132
|
+
.fail(function(error) {
|
133
|
+
console.error('Error fetching graph:', error);
|
134
|
+
});
|
135
|
+
}
|
136
|
+
|
137
|
+
function startStats() {
|
138
|
+
if (!updateStatsInterval) {
|
139
|
+
updateStats();
|
140
|
+
updateStatsInterval = setInterval(updateStats, 1000);
|
141
|
+
}
|
142
|
+
}
|
143
|
+
|
144
|
+
function startGraph() {
|
145
|
+
if (!updateGraphInterval) {
|
146
|
+
updateGraph();
|
147
|
+
updateGraphInterval = setInterval(updateGraph, 1000);
|
148
|
+
}
|
149
|
+
}
|
150
|
+
|
151
|
+
function stopStats() {
|
152
|
+
clearInterval(updateStatsInterval);
|
153
|
+
updateStatsInterval = null;
|
154
|
+
}
|
155
|
+
|
156
|
+
function stopGraph() {
|
157
|
+
clearInterval(updateGraphInterval);
|
158
|
+
updateGraphInterval = null;
|
159
|
+
}
|
160
|
+
|
161
|
+
$(document).ready(function() {
|
162
|
+
// Button handlers
|
163
|
+
$('#showStats').on('click', function() {
|
164
|
+
$('#statsPanel').show();
|
165
|
+
$('#graphPanel').hide();
|
166
|
+
stopGraph();
|
167
|
+
startStats();
|
168
|
+
});
|
169
|
+
|
170
|
+
$('#showGraph').on('click', function() {
|
171
|
+
$('#statsPanel').hide();
|
172
|
+
$('#graphPanel').show();
|
173
|
+
stopStats();
|
174
|
+
startGraph();
|
175
|
+
});
|
176
|
+
|
177
|
+
$('#showBoth').on('click', function() {
|
178
|
+
$('#statsPanel').show();
|
179
|
+
$('#graphPanel').show();
|
180
|
+
startStats();
|
181
|
+
startGraph();
|
182
|
+
});
|
183
|
+
|
184
|
+
// Initialize with both panels visible
|
185
|
+
$('#showBoth').click();
|
186
|
+
});
|
187
|
+
</script>
|
188
|
+
</body>
|
189
|
+
</html>
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.2
|
2
2
|
Name: dStats
|
3
|
-
Version: 1.0.
|
3
|
+
Version: 1.0.1
|
4
4
|
Summary: A real-time web-based monitoring tool that provides performance stats for Docker containers and visualizes their network connectivity graph
|
5
5
|
Home-page: https://github.com/Arifcse21/dStats
|
6
6
|
Author: Abdullah Al Arif
|
@@ -1,4 +1,5 @@
|
|
1
1
|
LICENSE
|
2
|
+
MANIFEST.in
|
2
3
|
README.md
|
3
4
|
setup.py
|
4
5
|
dStats/__init__.py
|
@@ -13,4 +14,5 @@ dStats.egg-info/SOURCES.txt
|
|
13
14
|
dStats.egg-info/dependency_links.txt
|
14
15
|
dStats.egg-info/entry_points.txt
|
15
16
|
dStats.egg-info/requires.txt
|
16
|
-
dStats.egg-info/top_level.txt
|
17
|
+
dStats.egg-info/top_level.txt
|
18
|
+
dStats/templates/dStats/index.html
|
@@ -2,7 +2,7 @@ from setuptools import setup, find_packages
|
|
2
2
|
|
3
3
|
setup(
|
4
4
|
name="dStats",
|
5
|
-
version="1.0.
|
5
|
+
version="1.0.1",
|
6
6
|
packages=find_packages(),
|
7
7
|
include_package_data=True,
|
8
8
|
description="A real-time web-based monitoring tool that provides performance stats for Docker containers and visualizes their network connectivity graph",
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|