Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compatibility with other webservers #8

Closed
gi-yt opened this issue May 17, 2022 · 2 comments
Closed

Compatibility with other webservers #8

gi-yt opened this issue May 17, 2022 · 2 comments

Comments

@gi-yt
Copy link

gi-yt commented May 17, 2022

Does this work on non-apache webservers which support cgi like nginx?

@tinoschroeter
Copy link
Owner

tinoschroeter commented May 20, 2022

@gi-yt If the web server supports cgi, this should work.

An example with nginx might look like this:

apt-get update; apt-get install -y nginx fcgiwrap

tee /etc/nginx/sites-enabled/default >/dev/null <<EOF
server {
        listen 80;
        location / {
        fastcgi_index index.cgi;
        try_files \$uri \$uri/ \$uri.html \$uri.cgi?\$query_string;
        gzip off;
        root /var/www/html;
        fastcgi_pass  unix:/var/run/fcgiwrap.socket;
        include /etc/nginx/fastcgi_params;
        fastcgi_param \SCRIPT_FILENAME  \$document_root\$fastcgi_script_name;
                   }
                   location ~* \.(js|jpg|png|css)$ {
                   root /var/www/;
                   expires 30d;
                   }
        }  
EOF

service nginx restart && service fcgiwrap restart 

@gi-yt
Copy link
Author

gi-yt commented May 28, 2022

thanks a lot!

@gi-yt gi-yt closed this as completed May 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants