mastermind
mastermind copied to clipboard
Run terminal commands via network request
It would be useful to run certain terminal commands via network request
An example of this is if you run http://proxapp:5000/network-toggle
it would enable/disable network, which would allow testing offline mode on ios simulator, it could be also used for custom commands to manipulate the server.
terminal command.
sudo ifconfig wlan0 down
sudo ifconfig wlan0 up
Thanks @Ashraf-Ali-aa :) At first looks like a good idea. Let me think a bit more about how it plays with the current implementation and future design. I'm a bit concern that this would couple the mastermind process to the host so removing the possibility to use things like Docker.
@arnau yes I agree with you that it would limit the scope, but on the other hand, it can also be a way to run custom scripts in order to help them set up an environment to test certain scenarios. An example of this could be load couple of images onto a device or set a proxy on an actual device via https://github.com/jpkrause/AndroidProxySetter etc. With this approach, the user can decide how they want to use the tool but still have an easy way to execute the commands via mastermind.
http://proxapp:5000/<user-Input>/command
I'm currently thinking in how to split Mastermind in client and server so the CLI is not bundled to Mastermind itself. I reckon it will take some time until I get to the point I can consider this proposal properly. Let's keep it open to keep the idea alive.