1

Topic: How to Install iRedmail with Discourse

==== REQUIRED BASIC INFO OF YOUR IREDMAIL SERVER ====
- iRedMail version (check /etc/iredmail-release):  Latest
- Linux/BSD distribution name and version: Centos 7 or ubuntu 18
- Store mail accounts in which backend (LDAP/MySQL/PGSQL):
- Web server (Apache or Nginx): Nginx
- Manage mail accounts with iRedAdmin-Pro?
- [IMPORTANT] Related original log or error message is required if you're experiencing an issue.
====

1. I have installed discourse on www.example.com and it was working fine with Nginx proxy. Then i installed iRedmail latest version and then i am able to login successfully to www.IP-address.com/iredadmin and www.IP-address.com/mail. But now i cant access to discourse. The domain www.example.com is not working. its showing "ssl redirect error". I am using Cloudflare flexible ssl and DNS.

2. Please guide me what to do? what am i doing wrong? Is there any other nginx block configuration or do i need to change any port?

3. I am using these 2 tutorials.
https://www.linuxbabe.com/mail-server/u … stallation
https://www.tecmint.com/install-discour … os-ubuntu/

Pls help

----

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

2

Re: How to Install iRedmail with Discourse

Do you have Nginx configuration for Disclourse after iRedMail installation? Is it loaded by Nginx?

3

Re: How to Install iRedmail with Discourse

ZhangHuangbin wrote:

Do you have Nginx configuration for Disclourse after iRedMail installation? Is it loaded by Nginx?

Yes, discourse has nginx config.

sudo nano /etc/nginx/conf.d/discourse.conf


server {
        listen 80;
        server_name  forum.tecmint.lan;

        location / {
                proxy_pass http://unix:/var/discourse/shared/standalone/nginx.http.sock:;
                proxy_set_header Host $http_host;
                proxy_http_version 1.1;
                proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
                proxy_set_header X-Forwarded-Proto $scheme;
        }
}

Here is the tutorial link....
https://www.tecmint.com/install-discour … os-ubuntu/

4

Re: How to Install iRedmail with Discourse

11assets wrote:

        server_name  forum.tecmint.lan;

Can you access this domain name? forum.tecmint.lan?

5 (edited by 11assets 2018-11-15 01:25:24)

Re: How to Install iRedmail with Discourse

1. No, no. This is just a dummy domain example.

If you share your email id then i will send my website details

2. iRedmail is working fine. I have tried discourse with and without nginx, but still discourse forum (www.example.com) is not opening. It's showing below errors in chrome....

(This page isn’t working domain.com redirected you too many times.
Try clearing your cookies.
ERR_TOO_MANY_REDIRECTS)

3. Discourse Start command is not working in CMD. Showing error like below....

(Error response from daemon: driver failed programming external connectivity on endpoint app (16c95fa34fb1219a89ce5f9629fe79bacb8ac01d7ac6d8a2c9800bce288b13bd): Error starting userland proxy: listen tcp 0.0.0.0:443: bind: address already in use
Error: failed to start containers: app)

4. May be i have found the problem. Its ssl issue. may be discourse needs new nginx with ssl configuration. I have disabled cloudflare flexible ssl and then i checked my site and it showed....

Secure Connection Failed
An error occurred during a connection to also11.com. Cannot communicate securely with peer: no common encryption algorithm(s). Error code: SSL_ERROR_NO_CYPHER_OVERLAP



5. I am using these 2 tutorials....pls check
https://www.linuxbabe.com/mail-server/u … stallation
https://www.tecmint.com/install-discour … os-ubuntu/

Pls help

6

Re: How to Install iRedmail with Discourse

11assets wrote:

3. Discourse Start command is not working in CMD. Showing error like below....

(Error response from daemon: driver failed programming external connectivity on endpoint app (16c95fa34fb1219a89ce5f9629fe79bacb8ac01d7ac6d8a2c9800bce288b13bd): Error starting userland proxy: listen tcp 0.0.0.0:443: bind: address already in use

I suppose Nginx is listening on port 80 AND 443, so your Discourse can not start due to it tries to bind to port 443.

7

Re: How to Install iRedmail with Discourse

1. yes, you found out the issue, but you dint tell me the solution. Please tell me a way to solve this. How to work with port 80 & 443 for iredmail and discourse together?

2. If i install discourse in vps1 with www.example.com domain and if i install iredmail in vps2 with www.webmail.example.com, then will this method work?