- '/data/extranet/www/fluidbook/cache/nwbuild:/usr/lib/node_modules/nw-builder/cache'\r
- '/home/toolbox/www:/home/toolbox/www'\r
- '/data/toolbox/:/data/toolbox/'\r
- - '/home/stats/www:/home/stats/www'\r
- '/home/wesco:/home/wesco'\r
# Config\r
- '/home/extranet/.docker/config/httpd/httpd.conf:/usr/local/apache2/conf/httpd.conf'\r
- '/data/extranet/www/fluidbook/cache/nwbuild:/usr/lib/node_modules/nw-builder/cache'\r
- '/home/toolbox/www:/home/toolbox/www'\r
- '/data/toolbox/:/data/toolbox/'\r
- - '/home/stats/www:/home/stats/www'\r
- '/home/wesco:/home/wesco'\r
# Config\r
- '/home/extranet/.docker/config/httpd/httpd-nb.conf:/usr/local/apache2/conf/httpd.conf'\r
# PHP\r
- '/home/extranet/.docker/config/php.ini:/etc/php/7.2/fpm/conf.d/99-overrides.ini'\r
- '/home/extranet/sessions/:/var/lib/php/sessions/'\r
- - '/usr/share/GeoIP/GeoIP.dat:/home/stats/www/GeoIP.dat'\r
# Crontab\r
- '/home/extranet/.docker/config/cron/crontab:/etc/crontab'\r
# Passwords\r
- '/data/extranet/www/fluidbook/cache/nwbuild:/usr/lib/node_modules/nw-builder/cache'\r
- '/home/toolbox/www:/home/toolbox/www'\r
- '/data/toolbox/:/data/toolbox/'\r
- - '/home/stats/www:/home/stats/www'\r
- '/home/wesco:/home/wesco'\r
tmpfs:\r
#- '/tmp:mode=777,uid=1002,gid=33'\r
options:\r
max-size: 10M\r
max-file: 10\r
+ privileged: true\r
+ cap_add:\r
+ - SYS_ADMIN\r
\r
redis:\r
container_name: extranet-redis\r
networks:\r
- extranet\r
restart: unless-stopped\r
+\r
networks:\r
extranet:\r
external:\r
\r
protected static function _getXLSFile($bid, $annee = null, $mois = null)\r
{\r
- self::forceComputation($bid);\r
+ if (rand(1, 50) == 20) {\r
+ self::forceComputation($bid);\r
+ }\r
$e = explode('_', $bid);\r
$bid = $e[0];\r
- $xname = '/home/stats/www/xls/' . $bid;\r
+ $xname = '/stats/xls/' . $bid;\r
if (!is_null($annee)) {\r
$xname .= '/' . $annee;\r
if (!is_null($mois)) {\r
{\r
global $core;\r
\r
- self::forceComputation($bid);\r
+ if (rand(1, 50) == 20) {\r
+ self::forceComputation($bid);\r
+ }\r
\r
cubePHP::set_memory('12G');\r
\r
$title = '';\r
\r
$colsTitles = array(__('Période'), /*__('Lieux de visite'),*/\r
- /*__('Visiteurs uniques'),*/ __('Visites'), __('Pages vues'));\r
+ /*__('Visiteurs uniques'),*/\r
+ __('Visites'), __('Pages vues'));\r
if ($afriend) {\r
$colsTitles[] = __('Liens envoyés');\r
}\r
public static function detailJour($book, $annee, $mois, $stats)\r
{\r
$colsTitles = array(__('Jour'), /*__('Lieux de visite'),*/\r
- /*__('Visiteurs uniques'),*/ __('Visites'), __('Pages vues'), __('Liens cliqués'));\r
+ /*__('Visiteurs uniques'),*/\r
+ __('Visites'), __('Pages vues'), __('Liens cliqués'));\r
$lines = array();\r
$xlines = array();\r
\r
}\r
$res = '<div class="graphStats"><div class="graph-note" style="top:' . $mhp . 'px;color:#514e49;">' . $maxpages . '</div>';\r
$res .= '<div class="graph-note" style="top:' . $mhb . 'px;color:#f54d00;">' . $maxb . '</div>';\r
- // $res .= '<div class="graph-note" style="top:' . $mhv . 'px;color:#c2d313;">' . $maxv . '</div>';\r
+ // $res .= '<div class="graph-note" style="top:' . $mhv . 'px;color:#c2d313;">' . $maxv . '</div>';\r
$res .= '<div class="graph-container" style="background:url(' . $imgw . ')"></div>';\r
$res .= '<table style="width:944px;max-width:944px;table-layout:fixed;" class="echelle"><tr>';\r
foreach ($months as $m => $t) {\r
$res .= '<table class="legende"><tr>';\r
$res .= '<td style="width:12px;background:#514e49;height:12px;"></td><td style="width:10px;"></td><td>' . __('Pages vues') . '</td><td style="width:10px;"></td>';\r
$res .= '<td style="width:12px;background:#f54d00;height:12px;"></td><td style="width:10px;"></td><td>' . __('Visites') . '</td><td style="width:10px;"></td>';\r
- // $res .= '<td style="width:12px;background:#c2d313;height:12px;"></td><td style="width:10px;"></td><td>' . __('Visiteurs uniques') . '</td><td style="width:10px;"></td>';\r
+ // $res .= '<td style="width:12px;background:#c2d313;height:12px;"></td><td style="width:10px;"></td><td>' . __('Visiteurs uniques') . '</td><td style="width:10px;"></td>';\r
$res .= '</tr></table></div>';\r
return $res;\r
}\r
}\r
$res = '<div class="graphStats"><div class="graph-note" style="top:' . $mhp . 'px;color:#514e49;">' . $maxpages . '</div>';\r
$res .= '<div class="graph-note" style="top:' . $mhb . 'px;color:#f54d00;">' . $maxb . '</div>';\r
- // $res .= '<div class="graph-note" style="top:' . $mhv . 'px;color:#c2d313;">' . $maxv . '</div>';\r
+ // $res .= '<div class="graph-note" style="top:' . $mhv . 'px;color:#c2d313;">' . $maxv . '</div>';\r
$res .= '<div class="graph-container" style="background:url(' . $imgw . ')"></div>';\r
$res .= '<table style="width:944px;max-width:944px;margin:0px;table-layout:fixed;" class="echelle"><tr>';\r
foreach ($days as $d => $t) {\r
$res .= '<table style="margin-top:10px;margin-bottom:10px;" class="legende"><tr>';\r
$res .= '<td style="width:12px;background:#514e49;height:12px;"></td><td style="width:10px;"></td><td>' . __('Pages vues') . '</td><td style="width:10px;"></td>';\r
$res .= '<td style="width:12px;background:#f54d00;height:12px;"></td><td style="width:10px;"></td><td>' . __('Visites') . '</td><td style="width:10px;"></td>';\r
- // $res .= '<td style="width:12px;background:#c2d313;height:12px;"></td><td style="width:10px;"></td><td>' . __('Visiteurs uniques') . '</td><td style="width:10px;"></td>';\r
+ // $res .= '<td style="width:12px;background:#c2d313;height:12px;"></td><td style="width:10px;"></td><td>' . __('Visiteurs uniques') . '</td><td style="width:10px;"></td>';\r
$res .= '</tr></table></div>';\r
return $res;\r
}\r
\r
public static function forceComputation($id)\r
{\r
- `/home/stats/www/FWStats.sh /home/stats/www onlybook=$id`;\r
- }\r
-\r
- /**\r
- * @return \Cubist\Matomo\Reporting\r
- */\r
- public static function getMatomoAPI(){\r
- return new \Cubist\Matomo\Reporting('https://v3.stats.fluidbook.com/','ebe362f44c01bda1ddedb75d7726ff78');\r
+ `/stats/FWStats.sh /stats onlybook=$id`;\r
}\r
}
\ No newline at end of file