Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Q: mods.php is not executed #21

Open
phit42 opened this issue Aug 24, 2021 · 4 comments
Open

Q: mods.php is not executed #21

phit42 opened this issue Aug 24, 2021 · 4 comments

Comments

@phit42
Copy link

phit42 commented Aug 24, 2021

Hi,
I know you have created a very detailed wiki, but I am still at a loss: I have created a simple package for one shell script. My original attempt to base it of Dummy did not work, so I based it of MODS Sample - Basic CGI. I replaced the item with my script and the generic package information, but left the rest intact. It successfully installs in my DSM, and creates the icon.
However, when executed via the menu icon, the script is not executed inside the DSM, but a new browser window is opened with the link to my mods.php (/webman/3rdparty/MyScriptsPackage/Shutdown_Rackstation/mods.php) and I am offered to save the mods.php on my local windows pc drive.

Mods Packager v7.3 DSM 6.2.4-25556

@vletroye
Copy link
Owner

Hi Phit

If you post your spk (possibly zipped), I will try it this weekend and look what's possibly worng.

That being said, I know that since the last update of DSM, my packages have issues.
I didn't have time yet to investigate.

V.

@phit42
Copy link
Author

phit42 commented Aug 27, 2021

Hi V,
thank you, very much appreciated. Here is the spk.

MyScriptsPackage.zip

@vletroye
Copy link
Owner

vletroye commented Aug 29, 2021

Ok.. I see. You didn't use the "Init 3rd Party" package to enable the execution of php script from the package folder or my cgi router trick... Although you did copy the Basic CGI sample, the router and the config file are not in your package

Regarding my cgi router trick, the best would have been tu use the "MODS Sample - Simple CGI". I should really refactor my documentation to make clear how to create a package from scratch

I did fix your package (including the option to run embedded in a DSM window):

MyScriptsPackage.zip

You will have to re-edit your script (I did echo your command for testing purpose)

image

Uninstall your version, refresh your browser (CTRL-F5), install the new one.

@phit42
Copy link
Author

phit42 commented Aug 29, 2021

I knew it, beginner's mistake. I am sorry! Thank you for taking the time and also fixing it.
I think I did try "simple CGI" as well before, but my efforts to bring in the correct cgi router trick configurations did not work.
Thanx for a great tool and your support.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants