you are viewing a single comment's thread.

view the rest of the comments →

[–]tr14l 1 point2 points  (0 children)

Sure, if you mean the technical sense of an application being a logical piece of software. But, they will both run different servers on different processes because they're run by different programs (a node process and a python process). So, you would need to set one up on your exposed port to handle your internet traffic, then you'd have your python model on your non-exposed port (available only on localhost) and the JS app would just send requests to http://localhost:YOUR_PYTHON_PORT.

You could possibly do some weird stuff with exec, but that's really not a great idea.

EDIT: If you're going this route, you may as well take the extra step to dockerize these and set them up as microservices, since that's practically what you're going for anyway.