Select Git revision
check_fs_writable
-
Hahn Axel (hahn) authoredHahn Axel (hahn) authored
dokuwiki.php 4.47 KiB
<?php
/* ______________________________________________________________________
*
* A P P M O N I T O R :: CLIENT - CHECK
* ______________________________________________________________________
*
* Check for a Dokuwiki instance.
* https://www.dokuwiki.org/
*
* @author: Axel Hahn - https://www.axel-hahn.de/
* ----------------------------------------------------------------------
* 2024-12-23 v1.00 ah initial version
* 2024-12-26 v1.01 ah fix directory checks
* 2025-01-06 v1.02 ah add df
*/
// ----------------------------------------------------------------------
// Init
// ----------------------------------------------------------------------
$aAppDefaults = [
"name" => "Dokuwiki",
"tags" => ["dokuwiki", "wiki"],
"df" => [
"warning" => "100MB",
"critical" => "10MB"
]
];
require 'inc_appcheck_start.php';
// ----------------------------------------------------------------------
// Read Concrete5 specific config items
// ----------------------------------------------------------------------
$sConfigfile = "$sApproot/conf/local.php";
if (!file_exists($sConfigfile)) {
header('HTTP/1.0 400 Bad request');
die('ERROR: Config file was not found. Use ?rel=[subdir] to set the correct subdir to find /conf/local.php.');
}
// ----------------------------------------------------------------------
// checks
// ----------------------------------------------------------------------
// required php modules
// see https://www.dokuwiki.org/install:php
$oMonitor->addCheck(
[
"name" => "PHP modules",
"description" => "Check needed PHP modules",
// "group" => "folder",
"check" => [
"function" => "Phpmodules",
"params" => [
"required" => [
"json",
"pcre",
"session",
],
"optional" => [
"bz2",
"gd",
"intl",
"mbstring",
"openssl",
"zlib"
],
],
],