diff --git a/.github/workflows/r_test.yml b/.github/workflows/r_test.yml index 6adabacdc1fcf..648b37bf20bda 100644 --- a/.github/workflows/r_test.yml +++ b/.github/workflows/r_test.yml @@ -49,17 +49,17 @@ jobs: - run: sudo systemctl daemon-reload - run: | - if sudo systemctl enable wazuh-indexer.service; then - sudo journalctl --no-pager -u wazuh-indexer.service - exit 1 + if ! sudo systemctl enable wazuh-indexer.service; then + sudo journalctl --no-pager -u wazuh-indexer.service + exit 1 fi - run: | - if sudo systemctl start wazuh-indexer; then + if ! sudo systemctl start wazuh-indexer; then sudo journalctl --no-pager -u wazuh-indexer.service exit 1 fi - run: | - if sudo systemctl status wazuh-indexer; then + if ! sudo systemctl status --no-pager wazuh-indexer -n 100; then sudo journalctl --no-pager -u wazuh-indexer.service exit 1 fi