my $sub = CGI::Compile->compile("/path/to/YOUR-SCRIPT.cgi"); my $app = CGI::Emulate::PSGI->handler($sub);