End of script output before headers line 118

When running on your local machine, it’s the same as running on a server as Standalone. When you deploy as CGI, a CGI script is created and uploaded with the app to control the application. Here’s a relevant thread that may help: