mirror of
https://github.com/Sabai-Technologies/sogo-docker.git
synced 2026-01-23 00:24:02 +00:00
88 lines
2.4 KiB
Nginx Configuration File
88 lines
2.4 KiB
Nginx Configuration File
user root;
|
|
worker_processes 5;
|
|
|
|
error_log /var/log/nginx/error.log warn;
|
|
pid /var/run/nginx.pid;
|
|
|
|
events {
|
|
worker_connections 1024;
|
|
}
|
|
|
|
http {
|
|
include /etc/nginx/mime.types;
|
|
default_type application/octet-stream;
|
|
|
|
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
|
|
'$status $body_bytes_sent "$http_referer" '
|
|
'"$http_user_agent" "$http_x_forwarded_for"';
|
|
|
|
access_log /var/log/nginx/access.log main;
|
|
|
|
sendfile on;
|
|
|
|
keepalive_timeout 65;
|
|
|
|
server {
|
|
listen 80;
|
|
listen [::]:80;
|
|
server_name localhost;
|
|
|
|
root /usr/lib/GNUstep/SOGo/WebServerResources;
|
|
|
|
proxy_set_header X-Forwarded-For $remote_addr;
|
|
|
|
add_header Strict-Transport-Security "max-age=31536000; includeSubDomains";
|
|
|
|
access_log /dev/stdout;
|
|
error_log /dev/stderr debug;
|
|
|
|
## requirement to create new calendars in Thunderbird ##
|
|
proxy_http_version 1.1;
|
|
|
|
location = / {
|
|
return 301 $scheme://$server_name/SOGo;
|
|
allow all;
|
|
}
|
|
|
|
location ^~/SOGo {
|
|
proxy_pass http://sogo:20000;
|
|
proxy_redirect `http://sogo:20000` default;
|
|
proxy_set_header X-Real-IP $remote_addr;
|
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
proxy_set_header Host $host;
|
|
proxy_set_header x-webobjects-server-protocol HTTP/1.0;
|
|
proxy_set_header x-webobjects-remote-host 127.0.0.1;
|
|
proxy_set_header x-webobjects-server-name $server_name;
|
|
proxy_set_header x-webobjects-server-url $scheme://$host;
|
|
proxy_set_header x-webobjects-server-port $server_port;
|
|
proxy_connect_timeout 90;
|
|
proxy_send_timeout 90;
|
|
proxy_read_timeout 90;
|
|
proxy_buffer_size 4k;
|
|
proxy_buffers 4 32k;
|
|
proxy_busy_buffers_size 64k;
|
|
proxy_temp_file_write_size 64k;
|
|
client_max_body_size 50m;
|
|
client_body_buffer_size 128k;
|
|
break;
|
|
}
|
|
|
|
location /SOGo.woa/WebServerResources/ {
|
|
alias /usr/lib/GNUstep/SOGo/WebServerResources/;
|
|
allow all;
|
|
}
|
|
|
|
location /SOGo/WebServerResources/ {
|
|
alias /usr/lib/GNUstep/SOGo/WebServerResources/;
|
|
allow all;
|
|
}
|
|
|
|
location (^/SOGo/so/ControlPanel/Products/([^/]*)/Resources/(.*)$) {
|
|
alias /usr/lib/GNUstep/SOGo/$1.SOGo/Resources/$2;
|
|
}
|
|
|
|
location (^/SOGo/so/ControlPanel/Products/[^/]*UI/Resources/.*\.(jpg|png|gif|css|js)$){
|
|
alias /usr/lib/GNUstep/SOGo/$1.SOGo/Resources/$2;
|
|
}
|
|
}
|
|
}
|