Results 1 to 2 of 2

Thread: Using Zimbra Behind Nginx

Hybrid View

  1. #1
    Join Date
    Feb 2012
    Posts
    1
    Rep Power
    3

    Default Using Zimbra Behind Nginx

    I run a small SOHO network. I NAT/port forward on my router to get traffic to my handful of servers.

    I setup an Ubuntu 10.04.4 server with Zimbra 7.1.4_GA_2555.FOSS. Let's call it host1.internal.local.

    The server currently has two mail domains, call them domain1.com and domain2.com. Both offer webmail access at webmail.domain1.com and webmail.domain2.com.

    I have a separate server with nginx. I want to configure nginx to reverse proxy to the Zimbra server, such that I can direct all HTTP/HTTPS to the nginx server and then distribute across other servers from nginx. I need to send webmail traffic via matched host address/headers to the Zimbra server.

    The basic configuration of:

    server {
    listen 80;
    server_name webmail.domain1.com;

    access_log /var/log/nginx/access.log main buffer=32k;
    error_log /var/log/nginx/error.log;

    location / {
    proxy_pass http://webmail.domain1.com;
    proxy_set_header Host $http_host;
    }
    }

    does not seem to work. (LAN DNS would resolve the http://webmail.domain1.com to the right server.) I get a 500 error. (The same config proxies regular www sites just fine.)

    Has anyone ever done anything like this? If so, how?

  2. #2
    Join Date
    Dec 2011
    Posts
    7
    Rep Power
    4

    Default

    i don't no if this will help but i have set up nginx in front of zimbra for https ( commercial certificate ) in the same machine.

    i have added the conf below in my virtual hosts env.
    Replace 127.0.0.1 with your LAN ip.

    Code:
    location / {
           proxy_pass  http://127.0.0.1:10000;
           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;
           proxy_connect_timeout 30;
           proxy_read_timeout 120;
           proxy_send_timeout 120;


    Tip : make sure that you have added in your conf :
    client_max_body_size 25m;
    to allow to attach files in your emails & briefcases

    I hope it helps!!

Similar Threads

  1. What to clean on a Zimbra mail server?
    By tezarin in forum Administrators
    Replies: 11
    Last Post: 12-16-2011, 12:43 PM
  2. Old Backup stay in TO_DELETE status and no clearing..
    By bartounet in forum Administrators
    Replies: 0
    Last Post: 10-05-2010, 08:40 AM
  3. [SOLVED] Clamav problem ? What's happening ?
    By aNt1X in forum Installation
    Replies: 23
    Last Post: 02-14-2008, 05:43 AM
  4. Can't start Zimbra!
    By zibra in forum Administrators
    Replies: 5
    Last Post: 03-22-2007, 12:34 PM
  5. zmtlsctl give LDAP error
    By sourcehound in forum Administrators
    Replies: 5
    Last Post: 03-11-2007, 04:48 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •