Hello,
If no error nor document appears then the macro hasn't been added to the correct .config directory. Please note that /var/www/wonder/.config seems the .config folder of the web user, if you are running it using the command line the correct .config folder should be in the home folder of the user. You can get the HOME folder (in the same way you are testing LibreOffice) using PHP:
<?php
echo getenv("HOME");
or changing to ~ folder.
We have tested the same steps using fresh installations of Debian, Ubuntu, CentOS, RedHat, Windows and macOS with LibreOffice 5 and LibreOffice 6, from PHP 5 to PHP 7.4 and in all cases adding the macro to the correct Module1.xba file, the conversion works correctly. Sorry but we don't know the issue without checking it, we'd need to connect to the server to test it.
Regards.