I'm looking for a way to automate an azure DW such that whenever my node.js webapp is started via IIS, it will start, and when the webapp is spun down, the DW will stop. This way, if my webapp is navigated to, the DW will begin the startup process. When the webapp is idle, the DW will turn off and not charge me a ton.
I imagine this can be done in one of two ways, and i was hoping to get some guidance for either way. I am not super familiar with the node project.
1: Is there a way that I can use something similar to a global.asax file in .NET but for node? In this way I can determine when IIS is spinning up / spinning down the webapp and call a powershell script at this time to start/stop the DW.
2: Is there a way to automate this process using runbooks or azure automation? I am familiar with using runbooks for simple on/off scheduling but don't know how to link it to the states of other app services...
3: maybe I can't do this in node/azure but it can be done in .NET and have a program that runs alongside my node.js, which will determine when IIS is starting/stopping the process and call a powershell script?
Any and all answers are appreciated.
via Jaked222
No comments:
Post a Comment