Hello McNeel Forums!
I am looking to call a cloud-hosted Cpython function from a hops component. I emulated the local flask server implementation demonstrated in the Hops Tutorial which runs smoothly. In an attempt to emulate a full AWS cloud implementation of a Cpython server (via Lambda or hosting the flask app via EC2, presuambly) I used ngrok to expose my local server to the internet, using the ngrok url (to my locally hosted flask server) as the endpoint in the hops component.
In order to prevent the default disabled loading from remote sources if hosted on a (ngrok) server, I added loadFromRemoteSources enabled="true"
to the Rhino executable configuration file, but though this resolved the initial error I found from exporting the REST API/python sample outputs from the hops component, the component still did not work. I also tried adding a test API key via grasshopper solver settings, to no avail.
My question is how best to host (a flask-based, hops-decorated) Cpython server online and call it from within grasshopper? Does this involve any special permissioning, potentially accomplished through grasshopper setting-Solver, or am I barking up the wrong tree?
Any help much appreciated!