Search code examples
webiiscommand-lineweb-applicationswebserver

How to deploy command-line program (exe) on IIS server?


I have a classical command-line program (exe), taking some parameters and doing some stuff. I would like to make it accessible via internet, i.e. via web browser. I have a Windows server with IIS web server and a running web site. Is there a way to deploy this exe command-line program directly? Can it be embedded into existing web site? If not, what is the way to proceed? If yes, how do I pass parameters to the exe program?


Solution

  • As far as I know, .exe cannot be deployed on iis server, because the web applicaion on IIS has to be configured to be able to run executables. if you want to run .exe through IIS, you can try it this way:

    1. Make your web site write a file that indicates the process needs to be run.
    2. Write a Windows ervice that runs on the web server that watches for the file that your web site creates.