nofxx-god_web 0.2.2 → 0.2.3
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/god_web.gemspec +6 -2
- data/lib/app.rb +13 -1
- data/lib/god_web.rb +1 -3
- data/public/app.css +23 -10
- data/public/icons/big_icon.png +0 -0
- data/public/icons/bookmark.png +0 -0
- data/public/icons/info.png +0 -0
- data/views/icon.erb +10 -0
- data/views/status.erb +10 -1
- data/views/watch.erb +7 -3
- metadata +6 -2
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.2.
|
1
|
+
0.2.3
|
data/god_web.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{god_web}
|
8
|
-
s.version = "0.2.
|
8
|
+
s.version = "0.2.3"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Jesse Newland", "Marcos Piccinini"]
|
12
|
-
s.date = %q{2009-09-
|
12
|
+
s.date = %q{2009-09-09}
|
13
13
|
s.default_executable = %q{god_web}
|
14
14
|
s.description = %q{iPhone friendly sinatra web UI for God}
|
15
15
|
s.email = %q{see@github.com}
|
@@ -32,9 +32,12 @@ Gem::Specification.new do |s|
|
|
32
32
|
"lib/god_web.rb",
|
33
33
|
"public/.DS_Store",
|
34
34
|
"public/app.css",
|
35
|
+
"public/icons/big_icon.png",
|
36
|
+
"public/icons/bookmark.png",
|
35
37
|
"public/icons/databases.png",
|
36
38
|
"public/icons/gear.png",
|
37
39
|
"public/icons/groups.png",
|
40
|
+
"public/icons/info.png",
|
38
41
|
"public/icons/key.png",
|
39
42
|
"public/icons/monitor.png",
|
40
43
|
"public/icons/restart.png",
|
@@ -74,6 +77,7 @@ Gem::Specification.new do |s|
|
|
74
77
|
"spec/god_web_spec.rb",
|
75
78
|
"spec/spec_helper.rb",
|
76
79
|
"views/command.erb",
|
80
|
+
"views/icon.erb",
|
77
81
|
"views/status.erb",
|
78
82
|
"views/watch.erb"
|
79
83
|
]
|
data/lib/app.rb
CHANGED
@@ -15,7 +15,9 @@ get '/' do
|
|
15
15
|
end
|
16
16
|
@watches.sort!
|
17
17
|
@groups = GODWEB.groups
|
18
|
-
|
18
|
+
@host = `hostname`
|
19
|
+
@footer = "GodWeb v0.2 - #{@host}"
|
20
|
+
show(:status, @host)
|
19
21
|
end
|
20
22
|
|
21
23
|
get '/w/:watch' do
|
@@ -42,6 +44,16 @@ get '/w/:watch/:command' do
|
|
42
44
|
show(:command, "#{@command}ing #{@watch}")
|
43
45
|
end
|
44
46
|
|
47
|
+
get '/o' do
|
48
|
+
@commands = %w{ quit restart }
|
49
|
+
show(:watch, "god itself")
|
50
|
+
end
|
51
|
+
|
52
|
+
get '/i' do
|
53
|
+
@text = `hostname`
|
54
|
+
show(:icon)
|
55
|
+
end
|
56
|
+
|
45
57
|
get '/heartbeat' do
|
46
58
|
@statuses = GODWEB.status
|
47
59
|
'OK'
|
data/lib/god_web.rb
CHANGED
data/public/app.css
CHANGED
@@ -1,14 +1,27 @@
|
|
1
|
-
body > ul > li {
|
2
|
-
|
1
|
+
body > ul > li { padding-left: 30px; }
|
2
|
+
li.unmonitored { background: transparent url(../icons/unmonitored.png) no-repeat scroll 8px 12px;}
|
3
|
+
li.unmonitor { background: transparent url(../icons/unmonitor.png) no-repeat scroll 8px 12px;}
|
4
|
+
li.monitor { background: transparent url(../icons/monitor.png) no-repeat scroll 8px 12px;}
|
5
|
+
li.start { background: transparent url(../icons/start.png) no-repeat scroll 8px 12px;}
|
6
|
+
li.stop { background: transparent url(../icons/stop.png) no-repeat scroll 8px 12px; }
|
7
|
+
li.quit { background: transparent url(../icons/stop.png) no-repeat scroll 8px 12px; }
|
8
|
+
li.restart { background: transparent url(../icons/restart.png) no-repeat scroll 8px 12px;}
|
9
|
+
li.groups { background: transparent url(../icons/groups.png) no-repeat scroll 8px 12px;}
|
10
|
+
li.god { background: transparent url(../icons/terminal.png) no-repeat scroll 8px 12px;}
|
11
|
+
li.hicon { background: transparent url(../icons/bookmark.png) no-repeat scroll 8px 12px;}
|
12
|
+
li.info { background: transparent url(../icons/info.png) no-repeat scroll 7px 7px;}
|
13
|
+
li.up { background: transparent url(../icons/up.png) no-repeat scroll 8px 12px;}
|
14
|
+
|
15
|
+
.home_icon_div {
|
16
|
+
padding-top: 80px;
|
17
|
+
background: transparent url(../icons/big_icon.png) no-repeat scroll center center;
|
18
|
+
font-size: 4em;
|
19
|
+
margin-bottom: 100px;
|
20
|
+
height: 300px;
|
21
|
+
font-weight: bold;
|
22
|
+
color: #4d4d70;
|
23
|
+
text-shadow: rgba(255, 255, 255, 0.75) 2px 2px 0;
|
3
24
|
}
|
4
|
-
li.up { background: transparent url(../icons/up.png) no-repeat scroll 8px 12px;}
|
5
|
-
li.unmonitored { background: transparent url(../icons/unmonitored.png) no-repeat scroll 8px 12px;}
|
6
|
-
li.monitor { background: transparent url(../icons/monitor.png) no-repeat scroll 8px 12px;}
|
7
|
-
li.start { background: transparent url(../icons/start.png) no-repeat scroll 8px 12px;}
|
8
|
-
li.stop { background: transparent url(../icons/stop.png) no-repeat scroll 8px 12px; }
|
9
|
-
li.restart { background: transparent url(../icons/restart.png) no-repeat scroll 8px 12px;}
|
10
|
-
li.unmonitor { background: transparent url(../icons/unmonitor.png) no-repeat scroll 8px 12px;}
|
11
|
-
li.groups { background: transparent url(../icons/groups.png) no-repeat scroll 8px 12px;}
|
12
25
|
|
13
26
|
.info {
|
14
27
|
font-size: 0.8em;
|
Binary file
|
Binary file
|
Binary file
|
data/views/icon.erb
ADDED
data/views/status.erb
CHANGED
@@ -13,7 +13,7 @@
|
|
13
13
|
<a id="backButton" class="button" href="#"></a>
|
14
14
|
<a class="button" href="/" target="_self">Refresh</a>
|
15
15
|
</div>
|
16
|
-
<ul id="home" selected="true" title="
|
16
|
+
<ul id="home" selected="true" title="<%= @title %>">
|
17
17
|
<% unless @groups.empty? %>
|
18
18
|
<li class="group">Groups</li>
|
19
19
|
<% @groups.each do |watch| %>
|
@@ -25,6 +25,15 @@
|
|
25
25
|
<li id="<%= watch %>" class="<%= @statuses[watch][:state] %>">
|
26
26
|
<a href="/w/<%= watch %>"><%= watch %></a></li>
|
27
27
|
<% end %>
|
28
|
+
<li class="group">Extras</li>
|
29
|
+
<li id="home_icon" class="hicon">
|
30
|
+
<a href="/i">Home Icon</a>
|
31
|
+
</li>
|
32
|
+
<li id="god_opts" class="god">
|
33
|
+
<a href="/o">God</a>
|
34
|
+
</li>
|
35
|
+
<li class="group">About</li>
|
36
|
+
<li class="info"><%= @footer %> [ok]</li>
|
28
37
|
</ul>
|
29
38
|
</body>
|
30
39
|
</html>
|
data/views/watch.erb
CHANGED
@@ -1,10 +1,14 @@
|
|
1
1
|
<ul id="<%= @watch %>_commands" title="<%= @title %>">
|
2
|
-
|
2
|
+
<% if @status %>
|
3
|
+
<li class="<%= @status %>"> <%= @status %> [<%= Time.now.strftime("%H:%m %m/%d") %>]</li>
|
4
|
+
<% end %>
|
3
5
|
<li class="group">Commands</li>
|
4
6
|
<% @commands.each do |command| %>
|
5
7
|
<li id="<%= command %>_<%= @watch %>" class="<%= command %>">
|
6
8
|
<a href="/w/<%= @watch %>/<%= command %>"><%= command %></a></li>
|
7
9
|
<% end %>
|
8
|
-
|
9
|
-
|
10
|
+
<% if @log %>
|
11
|
+
<li class="group">Log</li>
|
12
|
+
<div class="info"><p><%= @log %></p></div>
|
13
|
+
<% end %>
|
10
14
|
</ul>
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: nofxx-god_web
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jesse Newland
|
@@ -10,7 +10,7 @@ autorequire:
|
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
12
|
|
13
|
-
date: 2009-09-
|
13
|
+
date: 2009-09-09 00:00:00 -07:00
|
14
14
|
default_executable: god_web
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|
@@ -69,9 +69,12 @@ files:
|
|
69
69
|
- lib/god_web.rb
|
70
70
|
- public/.DS_Store
|
71
71
|
- public/app.css
|
72
|
+
- public/icons/big_icon.png
|
73
|
+
- public/icons/bookmark.png
|
72
74
|
- public/icons/databases.png
|
73
75
|
- public/icons/gear.png
|
74
76
|
- public/icons/groups.png
|
77
|
+
- public/icons/info.png
|
75
78
|
- public/icons/key.png
|
76
79
|
- public/icons/monitor.png
|
77
80
|
- public/icons/restart.png
|
@@ -111,6 +114,7 @@ files:
|
|
111
114
|
- spec/god_web_spec.rb
|
112
115
|
- spec/spec_helper.rb
|
113
116
|
- views/command.erb
|
117
|
+
- views/icon.erb
|
114
118
|
- views/status.erb
|
115
119
|
- views/watch.erb
|
116
120
|
has_rdoc: false
|