# Discourse with Cloudflare and Digital Ocean

**URL:** https://meta.discourse.org/t/discourse-with-cloudflare-and-digital-ocean/320099
**Category:** Self-hosting
**Tags:** nginx
**Created:** [August 5, 2024, 1:28am UTC](https://meta.discourse.org/t/discourse-with-cloudflare-and-digital-ocean/320099 "2024-08-05T01:28:06Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![lilacbull](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/lilacbull/32/437639_2.png) [@lilacbull](https://meta.discourse.org/u/lilacbull)
#### Post date: [August 5, 2024, 1:28am UTC](https://meta.discourse.org/t/discourse-with-cloudflare-and-digital-ocean/320099/1 "2024-08-05T01:28:06Z")

</div>

Hello! I’m a newcomer here trying to perhaps start a community with Discourse.

I started my journey with the following How-To on installing Discourse with Digital Ocean:

> <https://github.com/discourse/discourse/blob/main/docs/INSTALL-cloud.md>

I already had accounts with Cloudflare so it was natural for me to set up a domain there. After installing Discourse and making progress on setting things up, I hoped to adjust Cloudflare’s SSL/TLS to Full (Strict). I followed this How-To, which left me at a very basic position with Nginx:

> **[How To Host a Website Using Cloudflare and Nginx on Ubuntu 22.04 | DigitalOcean](https://www.digitalocean.com/community/tutorials/how-to-host-a-website-using-cloudflare-and-nginx-on-ubuntu-22-04)**
>
> In this tutorial, you will secure a website served by Nginx with an Origin CA certificate from Cloudflare and configure Nginx to use authenticated pull reque…

At this point I can turn on Full (Strict), and turned on Authenticated Origin Pulls. I just didn’t know how to have Nginx serve as a reverse proxy for Discourse from here.

Sadly, I can tinker on command line to get myself this far, but I am not familiar with Nginx. I did make a few good faith efforts to amend the app file on Discourse to some other port such as 12345:80.

From there I tried following other How-Tos which may not have been precisely for me:

I got stuck. I couldn’t make the changes on my own to get the Reverse Proxy going so I uninstalled Nginx for the time being and dialled down Full (Strict) and Authenticated Pulls.

Does anyone have any additional How-Tos or pointers?

---

<div class="post-metadata">

### Author: ![ljpp](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/ljpp/32/96506_2.png) [@ljpp](https://meta.discourse.org/u/ljpp)
#### Post date: [August 5, 2024, 2:05pm UTC](https://meta.discourse.org/t/discourse-with-cloudflare-and-digital-ocean/320099/2 "2024-08-05T14:05:56Z")

</div>

Why are you tinkering with Nginx, as the Discourse Docker installation, the default method, contains everything you need as a self-hoster?

Cloudflare works fine with Discourse.

---

<div class="post-metadata">

### Author: ![lilacbull](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/lilacbull/32/437639_2.png) [@lilacbull](https://meta.discourse.org/u/lilacbull)
#### Post date: [August 5, 2024, 11:40pm UTC](https://meta.discourse.org/t/discourse-with-cloudflare-and-digital-ocean/320099/3 "2024-08-05T23:40:05Z")

</div>

I’m not sure if that’s a rhetorical question.

I was trying to follow the recommendations laid out here under Best Practices.

[https://community.cloudflare.com/t/using-discourse-with-cloudflare-best-practices/602890](https://community.cloudflare.com/t/using-discourse-with-cloudflare-best-practices/602890)

I’m new to Discourse and this installation. If there is a How-To for ensuring I can properly turn on Full (Strict), that’s what I am looking for. If there is no need for such a step, then I am open to reviewing anything else that I should do to follow “Best Practices”

EDIT: After considering ljpp’s brief and insightful remark, I reviewed the Discourse installation instructions. I want to point out under the heading 11. (Optional) Add More Discourse Features, the How-To that I was looking for was under “Paid HTTPS / SSL support?”

Once I followed those steps, I EASILY managed to turn on Full (Strict) and I am pleased with the results.

I did not draw a connection that this was what I was looking for. I was accustomed to self-hosting projects as a hobbyist, and I am now enjoying the learning process for Discourse.

---

<div class="post-metadata">

### Author: ![system](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/system/32/443519_2.png) [@system](https://meta.discourse.org/u/system)
#### Post date: [September 4, 2024, 11:40pm UTC](https://meta.discourse.org/t/discourse-with-cloudflare-and-digital-ocean/320099/4 "2024-09-04T23:40:52Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
