1
0
Fork 0
mirror of https://gitlab.com/hagrid-keyserver/hagrid.git synced 2023-02-13 20:55:02 -05:00

about: add /about/stats page

This commit is contained in:
Vincent Breitmoser 2019-06-27 01:54:09 +02:00
parent 185a6eba16
commit fcd993fb45
No known key found for this signature in database
GPG key ID: 7BD18320DEADFA11
8 changed files with 46 additions and 8 deletions

View file

@ -1,6 +1,6 @@
{{#> layout }}
<div class="about">
<center><h2>About | <a href="/about/news">News</a> | <a href="/about/usage">Usage</a> | <a href="/about/faq">FAQ</a> | <a href="/about/privacy">Privacy Policy</a></h2></center>
<center><h2>About | <a href="/about/news">News</a> | <a href="/about/usage">Usage</a> | <a href="/about/faq">FAQ</a> | <a href="/about/stats">Stats</a> | <a href="/about/privacy">Privacy</a></h2></center>
<p>
The <tt>keys.openpgp.org</tt> server is a public service for the

View file

@ -1,6 +1,6 @@
{{#> layout }}
<div class="about">
<center><h2><a href="/about">About</a> | <a href="/about/usage">Usage</a> | <a href="/about/faq">FAQ</a> | <a href="/about/privacy">Privacy Policy</a> | API</h2></center>
<center><h2><a href="/about">About</a> | <a href="/about/news">News</a> | <a href="/about/usage">Usage</a> | <a href="/about/faq">FAQ</a> | <a href="/about/stats">Stats</a> | <a href="/about/privacy">Privacy</a></h2></center>
<p>
Hagrid implements both the legacy HKP interface, as well as our

View file

@ -1,7 +1,6 @@
{{#> layout }}
<div class="about">
<center><h2><a href="/about">About</a> | <a href="/about/news">News</a> | <a href="/about/usage">Usage</a> | FAQ | <a href="/about/privacy">Privacy Policy</a></h2></center>
<center><h2><a href="/about">About</a> | <a href="/about/news">News</a> | <a href="/about/usage">Usage</a> | FAQ | <a href="/about/stats">Stats</a> | <a href="/about/privacy">Privacy</a></h2></center>
<h3 id="no-sign-verified"><a href="#no-sign-verified">Why not sign keys
after verification?</a></h3>

View file

@ -1,6 +1,6 @@
{{#> layout }}
<div class="about">
<center><h2><a href="/about">About</a> | News | <a href="/about/usage">Usage</a> | <a href="/about/faq">FAQ</a> | <a href="/about/privacy">Privacy Policy</a></h2></center>
<center><h2><a href="/about">About</a> | News | <a href="/about/usage">Usage</a> | <a href="/about/faq">FAQ</a> | <a href="/about/stats">Stats</a> | <a href="/about/privacy">Privacy</a></h2></center>
<h3>
<div style="float: right; font-size: small; line-height: 2em;">2019-06-12 📅</div>

View file

@ -1,7 +1,6 @@
{{#> layout }}
<div class="about">
<center><h2><a href="/about">About</a> | <a href="/about/news">News</a> | <a href="/about/usage">Usage</a> | <a href="/about/faq">FAQ</a> | Privacy Policy</h2></center>
<center><h2><a href="/about">About</a> | <a href="/about/news">News</a> | <a href="/about/usage">Usage</a> | <a href="/about/faq">FAQ</a> | <a href="/about/stats">Stats</a> | Privacy</h2></center>
<p style="text-align: left;">
The public keyserver running on keys.openpgp.org processes, stores and

34
dist/templates/about/stats.html.hbs vendored Normal file
View file

@ -0,0 +1,34 @@
{{#> layout }}
<div class="about">
<center><h2><a href="/about">About</a> | <a href="/about/news">News</a> | <a href="/about/usage">Usage</a> | <a href="/about/faq">FAQ</a> | Stats | <a href="/about/privacy">Privacy</a></h2></center>
<h3>Verified e-mail addresses</h3>
<p>
A simple statistic of the total number of e-mail addresses that are currently verified. 📈
</p>
<p>
<center><img src="/about/stats/week.png" /></center>
</p>
<p>
<center><img src="/about/stats/month.png" /></center>
</p>
<h3>Load Average</h3>
<p>
The "load average" of a server is a statistic of how busy it is. Simply put:
<ul>
<li>0.0 means the <span class="brand">keys.openpgp.org</span> host is completely idle</li>
<li>1.0 is fairly busy</li>
<li>4.0 and above means it's on fire 🔥</li>
</ul>
</p>
<p>
<center><img src="/about/stats/load_week.png" /></center>
</p>
</div>
{{/layout}}

View file

@ -1,6 +1,6 @@
{{#> layout }}
<div class="about usage">
<center><h2><a href="/about">About</a> | <a href="/about/news">News</a> | Usage | <a href="/about/faq">FAQ</a> | <a href="/about/privacy">Privacy Policy</a></h2></center>
<center><h2><a href="/about">About</a> | <a href="/about/news">News</a> | Usage | <a href="/about/faq">FAQ</a> | <a href="/about/stats">Stats</a> | <a href="/about/privacy">Privacy</a></h2></center>
<p>
On this page, we collect information on how to use

View file

@ -305,6 +305,11 @@ fn apidoc() -> Template {
Template::render("about/api", templates::General::default())
}
#[get("/about/stats")]
fn stats() -> Template {
Template::render("about/stats", templates::General::default())
}
pub fn serve() -> Result<()> {
Err(rocket_factory(rocket::ignite())?.launch().into())
}
@ -320,6 +325,7 @@ fn rocket_factory(rocket: rocket::Rocket) -> Result<rocket::Rocket> {
faq,
usage,
files,
stats,
// VKSv1
vks_api::vks_v1_by_email,
vks_api::vks_v1_by_fingerprint,