diff --git a/mbadmin.jps b/mbadmin.jps index b7cd16a..8f5afef 100644 --- a/mbadmin.jps +++ b/mbadmin.jps @@ -846,22 +846,25 @@ actions: message: "${response.out}" redis_status: - cmd[cp]: + user: root commands: - - sudo systemctl list-units --type=service | grep redis + - systemctl list-units --type=service | grep -i redis || echo "No Redis service units found" - return: type: info message: "${response.out}" redis_disable: - cmd[cp]: + user: root commands: - - sudo systemctl stop redis + - systemctl stop redis - return: type: info message: "Redis has been stopped successfully" redis_enable: - cmd[cp]: + user: root commands: - - sudo systemctl restart redis + - systemctl restart redis - return: type: info message: "Redis has been successfully restarted"