I am looking for a more correct and complete answer that takes the form of my poorly imagined version of this:
- Use something like node or python to call a shell script that may or may not run as sudo
- That script might create a new folder to hold instance specific stuff (like client files, config, and or that instances database).
- The script or python code would deploy an instance of the application to that folder and on a specific port
- Python might add configuration information to a tool like Pound to forward a subdomain to a port
- Other things....!?
I don't really understand the high level steps that need to be taken here so if someone could provide those steps and maybe even some useful tools or tutorials for doing so I'd be extremely grateful.