Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Haack's Networking
haackingclub
Commits
12753660
Commit
12753660
authored
Apr 02, 2021
by
Haack's Networking
Browse files
renamed complex to proper name, removed stupid directory?
parent
132ddc7b
Changes
3
Hide whitespace changes
Inline
Side-by-side
nginx/serverblocks/basic.block.com
deleted
100644 → 0
View file @
132ddc7b
#this server block is better for custom css, javascript, html etc.
server {
listen 443 ssl;
listen [::]:443 ssl;
root /var/www/ladthejack.chickenkiller.com/html;
index index.html;
server_name ladthejack.chickenkiller.com;
location / {
try_files $uri $uri/ =404;
autoindex on;
}
#need to make this crt and key pair with openssl first
ssl_certificate /etc/ssl/certs/domain.com.crt
ssl_certificate_key /etc/ssl/private/domain.com.key
}
server {
if ($host = ladthejack.chickenkiller.com) {
return 301 https://$host$request_uri;
} # managed by Certbot
listen 80;
listen [::]:80;
server_name ladthejack.chickenkiller.com;
return 302 https://$server_name$request_uri;
}
nginx/serverblocks/complex.block.com
deleted
100644 → 0
View file @
132ddc7b
#use this one for a server block needing php, of course, also install php
#Oisin and Jonathan developed in 2019, perhaps summer.
server {
listen 443 ssl;
listen [::]:443 ssl;
root /var/www/daithiconri.mooo.com/html;
index index.html index.php;
server_name daithiconri.mooo.com;
location / {
try_files $uri $uri/ =404;
autoindex on;
}
location ~ \.php$ {
#try_files $uri =404;
include snippets/fastcgi-php.conf;
#specify where the php socket is
fastcgi_pass unix:/run/php/php7.4-fpm.sock;
#With php5-cgi alone:
#fastcgi_pass 127.0.0.1:9000;
#With php5-fpm:
#fastcgi_split_path_info ^(.+\.php)(/.+)$;
#fastcgi_pass unix:/var/run/php7.0-fpm.sock;
#fastcgi_index index.php;
#this is the param here that calls the conf.d directory ->
include fastcgi_params;
}
ssl_certificate /etc/letsencrypt/live/daithiconri.mooo.com/fullchain.pem; # managed by Certbot
ssl_certificate_key /etc/letsencrypt/live/daithiconri.mooo.com/privkey.pem; # managed by Certbot
}
server {
if ($host = daithiconri.mooo.com) {
return 301 https://$host$request_uri;
} # managed by Certbot
listen 80;
listen [::]:80;
server_name daithiconri.mooo.com;
return 302 https://$server_name$request_uri;
}
nginx/serverblocks/fastcgi-php.conf
deleted
100644 → 0
View file @
132ddc7b
# regex to split $uri to $fastcgi_script_name and $fastcgi_path
#this stays in /etc/nginx/snippets/ ...
#including here since it is called in the server blocks included in this repo
#(instead of the php being called directly in the block)
fastcgi_split_path_info
^(.+\.
php
)(/.+)$;
# Check that the PHP script exists before passing it
#try_files $fastcgi_script_name =404;
#change here ->
try_files
$
uri
$
uri
/ /
doku
.
php
;
# Bypass the fact that try_files resets $fastcgi_path_info
# see: http://trac.nginx.org/nginx/ticket/321
set
$
path_info
$
fastcgi_path_info
;
fastcgi_param
PATH_INFO
$
path_info
;
fastcgi_index
index
.
php
;
include
fastcgi
.
conf
;
include
fastcgi_params
;
fastcgi_param
SCRIPT_FILENAME
$
document_root
$
fastcgi_script_name
;
fastcgi_param
REDIRECT_STATUS
200
;
fastcgi_pass
unix
:/
run
/
php
/
php7
.
0
-
fpm
.
sock
;
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment