redis check
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
root
2024-08-05 19:29:52 +02:00
parent 74e162ff60
commit 46e7d51010
2 changed files with 14 additions and 4 deletions

View File

@@ -1,6 +1,6 @@
<?php
$REDIS_HOST='redis';
$REDIS_HOST='redis-server';
function ping_redis() {

View File

@@ -1,9 +1,19 @@
<?php
include "functions.php";
switch ($_GET["op"]) {
"redis":
echo ping_redis();
"docker":
case "redis":
try {
$ret = ping_redis();
if ($ret===false) {
echo "Can't ping redis-server";
}
else echo true;
} catch (RedisException $e) {
echo "RedisException caught: " . $e->getMessage();
}
break;
case "docker":
echo true;
break;