1

Topic: Nginx tutorial / help

==== Required information ====
- iRedMail version: 0.8.7 upgraded
- Store mail accounts in which backend (LDAP):
- Linux/BSD distribution name and version: Centos 6.5
- Related log if you're reporting an issue:
====

Hi Zhang,

I am trying to get Nginx to work with iRedMail, but am having trouble understanding some of the "shorthand" in the .conf files
https://bitbucket.org/zhb/iredmail/src/ … les/nginx/

I am new to Nginx, but realize its potential and would love to move over from Apache.

I'm not sure what the script is looking for here:
PH_RCM_HTTPD_ROOT_SYMBOL_LINK
SCRIPT_FILENAME
UWSGI_CHDIR PH_IREDADMIN_HTTPD_ROOT_SYMBOL_LINK
UWSGI_SCRIPT
PH_NGINX_MIME_TYPES


Can you point me in the right direction?

thanks

----

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

2

Re: Nginx tutorial / help

Only names which have a 'PH_' (place holder) prefix will be replaced after iRedMail installation, PH_[ABC] will be replaced by the value of variable 'ABC'. you can find all variable in file 'functions/nginx.sh', or files under 'conf/' directory. e.g. conf/roundcube, confi/nginx.

3 (edited by annonman 2014-07-27 00:16:29)

Re: Nginx tutorial / help

Thanks Zhang,

I have been able to get most of Nginx running, but I find I am having to change the sockets for  uWsgi to:

127.0.0.0:9001     




INSTEAD OF:

unix:/var/run/uwsgi_iredadmin.socket


After the change, everything runs fine.



nginx error.log:

connect() to unix:/var/run/uwsgi_iredadmin.socket failed (2: No such file or directory) while connecting to upstream

Do you know why this might be?

4

Re: Nginx tutorial / help

I found the issue.

the iredadmin.ini file lists

socket = PH_UWSGI_SOCKET_IREDADMIN

which I find:

https://bitbucket.org/zhb/iredmail/src/ … at=default

export UWSGI_SOCKET_IREDADMIN='unix:/var/run/uwsgi_iredadmin.socket'

so the socket is:

socket = unix:/var/run/uwsgi_iredadmin.socket

After removing 'unix:' and listing just the path, the socket is created and everything works.

I would call this a bug.

thanks

5

Re: Nginx tutorial / help

Thanks for your feedback, bug fixed.

6 (edited by vermus 2017-02-12 05:11:35)

Re: Nginx tutorial / help

iRedMail-0.9.6 same issue with nginx.

up. Seems, iredadmin uwsgi does't work.
I'm working on it.

this is strange, but it is helped:

service uwsgi stop
service uwsgi start