Attention ! Gitlab fournissant maintenant nativement des certificats Let’s Encrypt aux domaines personnalisés des Gitlab Pages, nous avons coupé notre service qui le faisait automatiquement pour vous.

Il est impératif, pour que votre domaine personnalisé continue à avoir un certificat Let’s Encrypt à jour, d’activer la fonctionnalité native dans les paramètres de votre projet. Cette activation remplacera votre certificat actuel par un nouveau certificat Let’s Encrypt géré par Gitlab.

Voir les détails sur https://docs.framasoft.org/fr/gitlab/gitlab-pages-le.html

Verified Commit ce2d7cf5 authored by Luc Didry's avatar Luc Didry

Add downloads count to stats

parent 530358d6
...@@ -49,14 +49,10 @@ sub fullstats { ...@@ -49,14 +49,10 @@ sub fullstats {
my $c = shift; my $c = shift;
my $stats = Lufi::DB::File->new(app => $c->app)->get_stats; my $stats = Lufi::DB::File->new(app => $c->app)->get_stats;
$stats->{timestamp} = time;
return $c->render( return $c->render(
json => { json => $stats
files => $stats->{files},
deleted => $stats->{deleted},
empty => $stats->{empty},
timestamp => time,
}
); );
} }
......
...@@ -275,8 +275,9 @@ sub get_stats { ...@@ -275,8 +275,9 @@ sub get_stats {
my $files = $c->app->dbi->db->query('SELECT count(short) AS count FROM files WHERE created_at IS NOT null AND deleted = ?', 0)->hashes->first->{count}; my $files = $c->app->dbi->db->query('SELECT count(short) AS count FROM files WHERE created_at IS NOT null AND deleted = ?', 0)->hashes->first->{count};
my $deleted = $c->app->dbi->db->query('SELECT count(short) AS count FROM files WHERE created_at IS NOT null AND deleted = ?', 1)->hashes->first->{count}; my $deleted = $c->app->dbi->db->query('SELECT count(short) AS count FROM files WHERE created_at IS NOT null AND deleted = ?', 1)->hashes->first->{count};
my $empty = $c->app->dbi->db->query('SELECT count(short) AS count FROM files WHERE created_at IS null')->hashes->first->{count}; my $empty = $c->app->dbi->db->query('SELECT count(short) AS count FROM files WHERE created_at IS null')->hashes->first->{count};
my $downloads = $c->app->dbi->db->query('SELECT SUM(counter) AS sum FROM files')->hashes->first->{sum};
return { files => $files, deleted => $deleted, empty => $empty }; return { files => $files, deleted => $deleted, empty => $empty, downloads => $downloads };
} }
=head2 from_short =head2 from_short
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment