performance-drupal/nginx-conf/nginx.conf
2022-10-10 08:26:41 +02:00

96 lines
2 KiB
Nginx Configuration File

server {
listen 80;
listen [::]:80;
server_name adminer.local;
index index.php;
location ~ ^/(index.php)?$ {
fastcgi_index index.php;
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME /var/www/html/index.php;
fastcgi_param DOCUMENT_ROOT /var/www/html/;
fastcgi_pass adminer:9000;
}
}
server {
listen 80;
listen [::]:80;
server_name devel.local;
index index.php index.html index.htm;
root /opt/drupal/web/;
location ~ /.well-known/acme-challenge {
allow all;
root /opt/drupal/web/;
}
location / {
try_files $uri $uri/ /index.php$is_args$args;
}
rewrite ^/core/authorize.php/core/authorize.php(.*)$ /core/authorize.php$1;
location ~ \.php$ {
try_files $uri =404;
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_pass drupal:9000;
fastcgi_index index.php;
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_param PATH_INFO $fastcgi_path_info;
}
location ~ /\.ht {
deny all;
}
location = /favicon.ico {
log_not_found off; access_log off;
}
location = /robots.txt {
log_not_found off; access_log off; allow all;
}
location ~* \.(css|gif|ico|jpeg|jpg|js|png)$ {
expires max;
log_not_found off;
}
}
server {
listen 80;
listen [::]:80;
server_name graphdb.local;
location / {
proxy_pass http://graphdb:7200;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
}
}
server {
listen 80;
listen [::]:80;
server_name solr.local;
location / {
proxy_pass http://solr:8983;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}
}