Skip to content

Commit ace30bc

Browse files
committed
Add usage in readme
1 parent e4be6f4 commit ace30bc

File tree

4 files changed

+65
-11
lines changed

4 files changed

+65
-11
lines changed

README.md

Lines changed: 26 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,26 @@
1-
# ceph-web
2-
Web based management tool for ceph
1+
# Ceph Web
2+
3+
## Introduction
4+
5+
Ceph-web is the management tool for ceph with full features.
6+
7+
* Easy to run with docker contaienr
8+
* Lightweight management tools
9+
* Full APIs from ceph-rest-api
10+
* Web UI with material design
11+
12+
![](./screenshot.png)
13+
14+
## Installation
15+
16+
```
17+
docker run -d -p 8080:8080 tobegit3hub/ceph-web
18+
```
19+
20+
## Notice
21+
22+
Ceph-web accesses official ceph-rest-api service. You can run [ceph/demo](https://github.com/ceph/ceph-docker/tree/master/demo) to setup all-in-one ceph cluster locally.
23+
24+
```
25+
docker run -d --net=host -e MON_IP=192.168.0.20 -e CEPH_NETWORK=192.168.0.0/24 ceph/demo
26+
```

controllers/default.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -274,8 +274,8 @@ type PgStat struct {
274274

275275
func (c *MainController) Get() {
276276

277-
//baseUrl := "http://127.0.0.1:5000/api/v0.1"
278-
baseUrl := "http://192.168.99.100:5000/api/v0.1"
277+
baseUrl := "http://127.0.0.1:5000/api/v0.1"
278+
//baseUrl := "http://192.168.99.100:5000/api/v0.1"
279279

280280
// Request health
281281
body := RequestJson(baseUrl + "/health")

screenshot.png

91.1 KB
Loading

views/index.tpl

Lines changed: 37 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,12 @@
6868
<!-- Health card -->
6969
<div class="panel panel-primary">
7070
<div class="panel-heading">
71-
<h3 class="panel-title">Ceph Status</h3>
71+
<span class="panel-title">Ceph Status</span>
72+
<!-- <span class="togglebutton">
73+
<label>
74+
&nbsp; &nbsp; &nbsp;<input type="checkbox" checked="">
75+
</label>
76+
</span> -->
7277
</div>
7378
<div class="panel-body">
7479
<p><b>Overall status:</b> {{.health.Output.OverallStatus}}</p>
@@ -80,7 +85,12 @@
8085
<!-- OSD disk free card -->
8186
<div class="panel panel-success">
8287
<div class="panel-heading">
83-
<h3 class="panel-title">OSD Disk Free</h3>
88+
<span class="panel-title">OSD Disk Free</span>
89+
<!-- <span class="togglebutton">
90+
<label>
91+
&nbsp; &nbsp; &nbsp;<input type="checkbox" checked="">
92+
</label>
93+
</span> -->
8494
</div>
8595
<div class="panel-body">
8696
<p><b>Total disk(KB):</b> {{.osdDf.Output.Summary.TotalKb}}</p>
@@ -96,7 +106,12 @@
96106
<!-- Osd crush dump card -->
97107
<div class="panel panel-warning">
98108
<div class="panel-heading">
99-
<h3 class="panel-title">OSD CRUSH Dump</h3>
109+
<span class="panel-title">OSD CRUSH Dump</span>
110+
<!-- <span class="togglebutton">
111+
<label>
112+
&nbsp; &nbsp; &nbsp;<input type="checkbox" checked="">
113+
</label> -->
114+
</span>
100115
</div>
101116
<div class="panel-body">
102117
<p><b>OSD Profile:</b> {{.osdCrushDump.Output.Tunables.Profile}}</p>
@@ -121,7 +136,12 @@
121136
<!-- Osd tree card -->
122137
<div class="panel panel-danger">
123138
<div class="panel-heading">
124-
<h3 class="panel-title">OSD Tree</h3>
139+
<span class="panel-title">OSD Tree</span>
140+
<!-- <span class="togglebutton">
141+
<label>
142+
&nbsp; &nbsp; &nbsp;<input type="checkbox" checked="">
143+
</label>
144+
</span> -->
125145
</div>
126146
<div class="panel-body">
127147
<p><b>Status:</b> {{.osdTree.Status}}</p>
@@ -131,7 +151,12 @@
131151
<!-- Pg status card -->
132152
<div class="panel panel-info">
133153
<div class="panel-heading">
134-
<h3 class="panel-title">PG Status</h3>
154+
<span class="panel-title">PG Status</span>
155+
<!-- <span class="togglebutton">
156+
<label>
157+
&nbsp; &nbsp; &nbsp;<input type="checkbox" checked="">
158+
</label>
159+
</span> -->
135160
</div>
136161
<div class="panel-body">
137162
<p><b>Num pgs:</b> {{.pgStat.Output.NumPgs}}</p>
@@ -146,7 +171,12 @@
146171
<!-- Mds status card -->
147172
<div class="panel panel-success">
148173
<div class="panel-heading">
149-
<h3 class="panel-title">MDS Status</h3>
174+
<span class="panel-title">MDS Status</span>
175+
<!-- <span class="togglebutton">
176+
<label>
177+
&nbsp; &nbsp; &nbsp;<input type="checkbox" checked="">
178+
</label>
179+
</span> -->
150180
</div>
151181
<div class="panel-body">
152182
<p><b>Fs name:</b> {{.mdsStat.Output.Mdsmap.FsName}}</p>
@@ -162,7 +192,7 @@
162192
<!-- All data is null, not used yet
163193
<div class="panel panel-primary">
164194
<div class="panel-heading">
165-
<h3 class="panel-title">MDS Compat Show</h3>
195+
<span class="panel-title">MDS Compat Show</span>
166196
</div>
167197
<div class="panel-body">
168198
<p><b>Compat:</b> {{.mdsCompatShow.Output.Compat}}</p>

0 commit comments

Comments
 (0)