intranet-system 1.1.0 → 1.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 762bbd8d9d53ca2709a85b3c96294aaaad67748db63158ed8a7c8e3148642192
|
4
|
+
data.tar.gz: f128d41ea61d665d87fd4b92e57b35ca23c8f098cb3917a996140fe9d822d85e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ee180354c3c6e21c06950e9554c20a8f6a2ffd2360e93d90ab85221c6f2ef0d4fd01095e3c8f125bc78f2ffedad0bd31054bc6f8e0beb6ae8f719322ecfa6128
|
7
|
+
data.tar.gz: 4be311d6aa627c09529efb15ca3b987ab5603d13043fd196049164402ab2e300e27907c1c4b1fc1fcd48f837fafbe1d0b4c005b283260b1099816868059f0a64
|
@@ -22,13 +22,14 @@ module Intranet
|
|
22
22
|
|
23
23
|
# Initializes a new Linux statistics provider.
|
24
24
|
def initialize
|
25
|
-
@stats =
|
25
|
+
@stats = {
|
26
26
|
hostname: Socket.gethostname,
|
27
27
|
loadavg: nil,
|
28
28
|
cpu: { model: cpu_model, nb_cores: nb_cores },
|
29
29
|
ram: { total: ram_available },
|
30
30
|
swaps: {},
|
31
|
-
partitions: {}
|
31
|
+
partitions: {}
|
32
|
+
}
|
32
33
|
@stats_date = Time.now - STATS_REFRESH_DELAY_S
|
33
34
|
end
|
34
35
|
|
@@ -89,31 +89,33 @@ RSpec.describe Intranet::System::Responder do
|
|
89
89
|
expect(code).to eql(206)
|
90
90
|
expect(mime).to eql('text/html')
|
91
91
|
expect(content).to eql(
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
92
|
+
{
|
93
|
+
content: "<section>\n<h2>#{I18n.t('system.monitor')}</h2>\n" \
|
94
|
+
"<ul class='breadcrumb'>\n" \
|
95
|
+
"<li>\n<a href='/index.html'>#{I18n.t('nav.home')}</a>\n</li>\n" \
|
96
|
+
"<li>#{I18n.t('system.monitor')}</li>\n" \
|
97
|
+
"</ul>\n\n" \
|
98
|
+
"<h3 id='cpu_model'>#{I18n.t('system.processor')} : </h3>\n" \
|
99
|
+
"<p class='meter' id='load1min'>\n<span class='desc'>1 min</span>\n<span cla" \
|
100
|
+
"ss='info'>0.00</span>\n<meter high='90' low='80' max='100' min='0' optimum=" \
|
101
|
+
"'50' title='0 %' value='0'></meter>\n</p>\n" \
|
102
|
+
"<p class='meter' id='load5min'>\n<span class='desc'>5 min</span>\n<span cla" \
|
103
|
+
"ss='info'>0.00</span>\n<meter high='90' low='80' max='100' min='0' optimum=" \
|
104
|
+
"'50' title='0 %' value='0'></meter>\n</p>\n" \
|
105
|
+
"<p class='meter' id='load15min'>\n<span class='desc'>15 min</span>\n<span c" \
|
106
|
+
"lass='info'>0.00</span>\n<meter high='90' low='80' max='100' min='0' optimu" \
|
107
|
+
"m='50' title='0 %' value='0'></meter>\n</p>\n" \
|
108
|
+
"<h3>#{I18n.t('system.memory')}</h3>\n" \
|
109
|
+
"<p class='meter' id='ram'>\n<span class='desc'>RAM</span>\n<span class='inf" \
|
110
|
+
"o'>0 M#{I18n.t('system.byte_abbrev')} #{I18n.t('system.out_of')} 0 M" \
|
111
|
+
"#{I18n.t('system.byte_abbrev')}</span>\n<meter high='90' low='80' max='100'" \
|
112
|
+
" min='0' optimum='50' title='0 %' value='0'></meter>\n</p>\n" \
|
113
|
+
"<div class='loading' id='swaps'></div>\n" \
|
114
|
+
"<h3>#{I18n.t('system.storage')}</h3>\n" \
|
115
|
+
"<div class='loading' id='storage'></div>\n" \
|
116
|
+
"</section>\n",
|
117
|
+
title: I18n.t('system.monitor')
|
118
|
+
}
|
117
119
|
)
|
118
120
|
end
|
119
121
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: intranet-system
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ebling Mis
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-05-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: intranet-core
|