A quick way to install SSL certificates is to add the ssl_options to your HTTPServer, using the os.path.join with a relative folder location, and the file name (this works on both Windows and Linux, just keep in mind you need to use the os.path.join function).

The second step is to make sure your RequestHandler redirects to your using HTTPS protocol by doing a redirect on the prepare method as shown below.

The full code for the application is shown below:

--

--

There are a few ways, a solid way to start this is to create a bat file and create a task that is execute when the Windows server starts, the following command will run a bat file location in the C:\dev folder as a task during startup:

schtasks.exe /create /tn “Tornado App Server” /ru SYSTEM /Sc ONSTART /tr “C:\dev\tornado_startup.bat”

Creating the task is not always an option, as IT might have locked down the server. Another way to achieve the start up functionality is by doing the following:

The shell:startup command will bring a folder, where you can place your script in and it gets executed during start up.

For a sample project containing the script take a look at my git repo.

--

--

[ ALESSANDRO ]

[ ALESSANDRO ]

Full mobile stack developer, researcher, and simulation software developer.