how to set 'www' in discourse (docker installation)

September 9, 2018 542 views
Let's Encrypt Applications Ubuntu 18.04

Hi guys, I have installed discourse from docker in a Ubuntu 18 server, and I'm also using digitalocean to manage my domain. My discourse installation works fine in, in fact, I set that domain when I setup the app ( ./discourse-setup ). Then I add an A record "www" pointing to my server ip, but when I visit, I get Your connection is not private errorr :(

How can I to dd that 'www' subdomain to discourse, using LetsEncrypt? I want: www redirect to non-www, and works fine with https.

I hope you can help me and sorry for my english : )

2 Answers

Hey friend!

Currently Discourse does not support more than one hostname. With that said, I'm running the same setup at a website of mine and I noticed that it has covered requests to www over https without error, and is redirecting them to my non-www page. I've not dug into the Nginx/LE config for Discourse recently, but that seems intentional. All I did was point mydomain.tld to the droplet IP, point www as a CNAME to mydomain.tld, and then installed Discourse while giving it the mydomain.tld URL to set itself up on.


hi, thanks for answer, so all should I do is add a cname subdomian "" pinting to my "" (wich I will set as hostname in discourse installation)?

"www" should be cname or A record?
"www" should point to or droplet ip?

Have another answer? Share your knowledge.