diff options
author | Cirakg <cirakg@cirakg.xyz> | 2025-04-13 19:38:03 +0200 |
---|---|---|
committer | Cirakg <cirakg@cirakg.xyz> | 2025-04-13 19:38:03 +0200 |
commit | 4d514ccd7c2d6b7346e06dd3aa87f87b4deae5c4 (patch) | |
tree | d79d92bb842812f0479c77d7f689144b59803aee | |
parent | 483d55fc933e427df817e5d7804db234deffc612 (diff) |
docs: Update README.md.
-rw-r--r-- | README.md | 49 |
1 files changed, 48 insertions, 1 deletions
@@ -1 +1,48 @@ -# Paste-cgi
\ No newline at end of file +# Paste-cgi + +``` +server { + + server_name SERVERURL; + root ROOTFOLDER; + + location / { + auth_basic "Restricted Content"; # Basic Auth + auth_basic_user_file /etc/nginx/.htpasswd; # Basic Auth + include fastcgi_params; + fastcgi_param SCRIPT_FILENAME PATH TO SCRIPT; + fastcgi_param PATH_INFO $uri; + fastcgi_param QUERY_STRING $args; + fastcgi_param HTTP_HOST $server_name; + fastcgi_param CONTENT_LENGTH $content_length; + fastcgi_param CONTENT_TYPE $content_type; + fastcgi_param ALLOWED_DIR PATH WHERE THE ALLOWED DIRECTORY IS TO CHANGE FILES; + fastcgi_pass unix:/run/fcgiwrap.socket; + } + + + listen [::]:443 ssl; # managed by Certbot + listen 443 ssl; # managed by Certbot + ssl_certificate /etc/letsencrypt/live/paste.cirakg.xyz/fullchain.pem; # managed by Certbot + ssl_certificate_key /etc/letsencrypt/live/paste.cirakg.xyz/privkey.pem; # managed by Certbot + include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot + ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot + +} +server { + if ($host = paste.cirakg.xyz) { + return 301 https://$host$request_uri; + } # managed by Certbot + + + + listen 80; + listen [::]:80; + + server_name paste.cirakg.xyz; + return 404; # managed by Certbot + + +} + +```
\ No newline at end of file |