1 (edited by maxyca 2024-01-13 00:11:28)

Topic: Nginx frontend + iredmail backend

==== REQUIRED BASIC INFO OF YOUR IREDMAIL SERVER ====
- iRedMail version (check /etc/iredmail-release): 1.6.8
- Linux/BSD distribution name and version: Ubuntu 20.04
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): MySQL
- Web server (Apache or Nginx): Nginx
- Manage mail accounts with iRedAdmin-Pro? No

====
Hi all!
Is there a recommended nginx config for frontend (it also receives LE certificates and copies them to iredmail nginx backend via scp)?
There is my confing (frontend):
```
server {
        listen 80;
        server_name mail.example.com;
        return 301 https://$host$request_uri;
}

server {
      listen 443 ssl http2;
    server_name mail.example.com;
   
    client_header_buffer_size 1k;
    large_client_header_buffers 4 4k;

    access_log /var/log/nginx/mail.example.com-access.log;
    error_log /var/log/nginx/mail.example.com-error.log;

    ssl_certificate /etc/letsencrypt/live/mail.example.com/fullchain.pem;
    ssl_certificate_key /etc/letsencrypt/live/mail.example.com/privkey.pem;
   
        location / {
            proxy_pass https://10.77.50.85;
            proxy_redirect     off;
            proxy_set_header   Host             $host;
            proxy_set_header   X-Real-IP        $remote_addr;
            proxy_set_header   X-Forwarded-For  $proxy_add_x_forwarded_for;           
            client_max_body_size 0;
            proxy_buffer_size 128k;
            proxy_buffers 64 512k;
            proxy_busy_buffers_size 512k;
       
    }

}
```

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2

Re: Nginx frontend + iredmail backend

What's the role of such "nginx frontend"?