Good afternoon,
Let me start off by explaining what I am trying to do.
I am running a webserver that utilizes MODx as a CMS (no experience necessary to address my issue) and PHP scripts to run automated commands.
The CMS has an "admin" side which allows the user to create scripts and design their pages.
I have a specific page that is running a script that will take a cloud file and run it through a few external programs (locally installed on the server, external to MODx). There are two programs being used, CloudCOmpare and one unnamed.
The PHP script is using EXEC() to run commands to deploy and give commands to the external programs.
For the unnamed program, the script works great locally through a terminal as well as through the MODx(CMS) call to run the script.
(I did have to set the script to run as a program and give directories affected 777 permissions temporarily for testing)
However, when I try the same for CloudCompare, the script works if ran directly from a terminal, but fails to do anything when executed via MODx, but also gives no error codes. (The script runs successfully, but the cloudcompare components of the script do not work when executed from MODx).
I believe this may have something to with the installation for CloudCompare as I used the snap install. This creates some kind of namespace and reference to snaps directories (I am unfamiliar with snap and namespaces). Do you or anyone know what could be causing this extremely vague error?
If not, is there any detailed, step-by-step updated Linux build instructions for CloudCompare (running Ubunto 16)? I have a suspicion that if I were to build/ compile CloudCompare similar to how I would on windows, giving me a CloudCompare directory with an executable, that this "error" would cease to exist as it would an identical setup as the "unnamed" program, which was successful.
(many questions revolving around installign CC on linux keep resulting in a suggestion to use snap, which could be part of my problem...)
Respectfully,
Linux - Webserver PHP script
Re: Linux - Webserver PHP script
I should also mention this is the command running in the EXEC() php function for CloudCompare:
"
$cloudcompareCommand = "cloudcompare.CloudCompare -SILENT -o /home/eco3d/public_html/VaultFS/assecovault/Project2/las-viewer/test-scene-e57-55scans.e57 -MERGE_CLOUDS";
exec($cloudcompareCommand,$phpOutput); (have also tried shell_exec() with just the command parameter for input)
"
*The bold/underlined text runs flawlessly if executed in a terminal directly on ubuntu.
"
$cloudcompareCommand = "cloudcompare.CloudCompare -SILENT -o /home/eco3d/public_html/VaultFS/assecovault/Project2/las-viewer/test-scene-e57-55scans.e57 -MERGE_CLOUDS";
exec($cloudcompareCommand,$phpOutput); (have also tried shell_exec() with just the command parameter for input)
"
*The bold/underlined text runs flawlessly if executed in a terminal directly on ubuntu.