Publish an App to *.meteor.com that uses child_process.exec()


#1

I have a project that makes use of nodejs’s child_process.exec to handle things like controlling the server’s wireless interfaces and network connections. This is because the app is intended to be used as a local web app, through Electron.

However, it can also function as a browser-based tool.

I have made a project that features an example of both modes of operation. I’d like to deploy it to *.meteor.com to share with others who are interested in the same sorts of applications (SoftAP setup from the browser).

In the case of such a hosting situation, obviously these .exec() calls would be useless – they would be running on some server, which is not client’s computer, and I’ve included language in the demo app that indicates they should not expect these features to function if they’re visiting the remote demo.

But my question is: is it safe for me to deploy the project to *.meteor.com? What I’d like is for those server-side .exec commands (to netsh, airport, networksetup, nmcli, etc.) to merely fail on the demo server. I have included error-handling around all calls to the system’s shell that will report the status to the client. Demo users will understand why those features are not available – but I want to make sure that I will not be causing harm to the Meteor hosting environment or producing problems for other users or sys admins.

I would much prefer to not have to surgically remove those code, since I want to keep it functional in my repo so that users can clone it, run it locally, and compile their own Electrified executables of it to try the full features out on their own machines.