All Questions
28
questions
0
votes
3
answers
598
views
CGI scripts: when can you return a document, instead of an HTTP response?
Script 1 below is bash, and is at https://example.com/cgi-bin/test. It produces the output 'Under construction' when fetched. It echos Status and Content-type headers, and some HTML. If I instead try ...
0
votes
1
answer
752
views
How to Enable Immediate CGI Line Outputs With Nginx, Without Waiting for a CGI Script to Finish?
I have a perl and shell script that process a bunch of data and output results as they happen, like:
5 processed in 0.58 seconds.
10 processed in 0.79 seconds.
...
150 processed in 0.65 seconds. DONE!
...
1
vote
0
answers
4k
views
nginx site shows blank page. No errors
Background
I'm trying to get an nginx /php-fpm7 site up and running on an alpine linux server.
Problem
No errors appear when i navigate to it. Cert is good. And the in the /var/log/access.log ...
1
vote
1
answer
750
views
SELinux, Nginx and fcgiWrap: how to allow access to fcgiWrap socket?
I am under Fedora 31 (linux kernel 5.4.13, Nginx 1.16.1, fcgiwrap 1.1.0) running with SELinux in enforcing mode (policy: targeted 3.14.4-44.fc31).
My box hosts a server driven by Nginx. Part of it ...
1
vote
1
answer
903
views
Loading css from cgit on nginx in a subdirectory
before I start I should note that I have absolutely no experience with nginx or networking, so what I have done was thanks to searching and trying different solutions.
I have a problem I struggle ...
5
votes
2
answers
14k
views
What is the difference between a proxy server and a gateway server?
From Proxy server on Wikipedia:
A proxy server may reside on the user's local computer, or at any
point between the user's computer and destination servers on the
Internet. A proxy server that passes ...
1
vote
1
answer
192
views
What can be a FastCGI client?
fcgiweb is a server based on FastCGI protocol.
What can be a FastCGI client? Is a CGI script a FastCGI client, or is a web server (e.g. Nginx) a FastCGI client?
Thanks.
0
votes
0
answers
442
views
How can I configure Nginx to use PHP in CGI-mode?
The Nginx tutorial shows PHP 5 being used in FastCGI mode on Windows, but PHP 4 doesn't support php-cgi.exe so it must be run in traditional cgi mode,
There are two ways to set up PHP to work with ...
5
votes
1
answer
1k
views
Nginx and fcgiwrap, incremental output problems
When I run a cgi script under Apache any output is rapidly sent to the client. However when I run it under nginx with fcgiwrap it seems nothing is sent to the client until the script either finishes ...
0
votes
1
answer
2k
views
CGI stopped working on setting Nginx as reverse proxy for apache
So I am running a site www.example.com. Initially, I was using apache and any hit to my site would be redirected to www.example.com/path.
Now this redirection is defined in my httpd.conf like:
...
1
vote
1
answer
1k
views
Nginx serving C++ cgi script: response is binary format
I am trying to run C++ CGI script on nginx. I am using FCGIWrap with script from nginx website. The program code is like this:
#include <iostream>
using namespace std;
int main ()
{
cout &...
1
vote
1
answer
2k
views
uwsgi configuration with Nginx, with python scripts as cgi - 502 Bad Gateway
This is my .ini file to run the uwsgi "pyApp.py"
[uwsgi]
plugins = cgi
socket = 127.0.0.1:9010
cgi = /=/usr/share/test/
cgi-allowed-ext = .py
cgi-helper = .py=python
i have a file "firstapp.py" at ...
3
votes
1
answer
1k
views
cgit only works on command line, but not with nginx
Like many times, I used a virtual machine to test something. This is the reason why the configuration is maybe a bit dirty. I just try to get cgit running with nginx.
I created a directory /git (...
1
vote
0
answers
163
views
nginx can't find cgi two levels deep
Typically, I want to serve an index.html file when http://mysite.com/ and any other directory is requested. The following, in nginx.conf, does that for /test:
location /test {
try_files $uri.html ...
0
votes
1
answer
6k
views
how is it possible to configure uwsgi in emperor-mode with cgi-plugin + heartbeat in combination with nginx
After having the migration from fcgiwrap to uWSGI (which also brings plenty of other benefits that I'm planning to use) on my ToDo-list for some time I finally managed to setup a debian-wheezy test-...
7
votes
1
answer
3k
views
How to debug CGI over fcgiwrap/nginx
I serve executable scripts (mainly in C) through fcgiwrap connected with nginx. Since the scripts are complied, I can get the coding errors during compilation, but sometimes I receive CGI errors ...
6
votes
1
answer
9k
views
nginx + fcgiwrap: how come order of fastcgi_param matters?
I'm running Debian 6.0.3 (squeeze), nginx-0.7.67, fcgiwrap-1.0-1+squeeze1. Here is the test script:
#!/usr/bin/perl
use 5.010;
use warnings;
use strict;
use Data::Dumper;
print "Content-Type: text/...
2
votes
1
answer
1k
views
CGI permissions with NGINX & FastCGI
I'm running GitWeb (which is essentially a CGI script) on a server which also runs GitLab. My aim is to provide reaad-only access to GitLab repositories without registering people.
I've pointed ...
1
vote
0
answers
1k
views
NGINX and CGit configuration
I?m trying to setup CGit and NGINX. I'm almost there but I have a problem with the rewrite rule in my NGINX's conf file.
Currently I have this:
server {
listen 80;
server_name cgit....
0
votes
1
answer
1k
views
Chrooted nginx, fastcgi, and cgit
I'm running a Debian server with nginx chrooted in /var/chroot/nginx. It works wonderfully, but I'd like to be able to run cgit and host my gitolite repositories.
When it was out of the chroot it ...
0
votes
1
answer
925
views
Webserver Nginx + PHP FPM Access Denied error with .cgi scripts
Webserver with Nginx 1.1.19 and PHP 5 FPM work great with serving PHP and showing output of mysql data.
I want to embed nagios in my application and so I needed .cgi scripts for the first time on ...
0
votes
1
answer
3k
views
Nginx + fastcgi to run PHP script , but it kept telling me "File not found"
Here's part of config in the server block:
I was unable to execute any php script , I placed a file named test.php under /var/html , but when I point to http://localhost/test.php , I got a result:
...
0
votes
1
answer
367
views
Compiling FastCGIWrap fails on slackware (nginx cgi support)
I'm currently trying to get nginx to work with cgit which uses cgi.
I know nginx doesn't support cgi directly but it appears you can support it indirectly via FastCGIWrap.
The link above is pretty ...
1
vote
2
answers
2k
views
Is there any equivalent to php5-cgi for python?
nginx doesn't allow to directly execute external programs, so to run CGIs you need to run an standalone fcgi backend and connect to it with the fastcgi_pass directive.
For php it's easy, e.g. using ...
3
votes
3
answers
1k
views
Can advanced web servers be faster than basic web servers?
A bsic web server such as python SimpleHTTPServer or THTTPD reads static files with least process; thus is quite fast. Normally, adding more features to create an advanced web server (but still ...
3
votes
2
answers
928
views
how to spawn php-cgi automatically when it exits?
I am using php-cgi on ubuntu(with nginx), and the command to start it is:
spawn-fcgi -a 127.0.0.1 -p 9100 -f /usr/bin/php-cgi -P /var/run/fastcgi-php.pid
but sometimes the php-cgi process will exit ...
2
votes
2
answers
2k
views
How does nginx support cgi?
With apache ,I just put my binary under cgi-bin,how about nginx?
Does it support cgi at all?
3
votes
4
answers
7k
views
How to add a pool to FPM (nginx) without reload/restart fpm itself?
Im building an environment (on a ubuntu 10.04.02 machine) to handle a website with many (should support at least 1000) subdomains, each of them served by a different FPM pool, with a different user.
...