# Issue with Cloudflare template

**URL:** <https://meta.discourse.org/t/issue-with-cloudflare-template/35113>\
**Category:** Bug\
**Created:** [2015 年 10 月 30 日午後 5:52 UTC](https://meta.discourse.org/t/issue-with-cloudflare-template/35113 "2015-10-30T17:52:00Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

**Author:** ![Stephen](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/stephen/32/95011_2.png) [@Stephen](https://meta.discourse.org/u/Stephen)\
**Post date:** [2015 年 10 月 30 日午後 5:52 UTC](https://meta.discourse.org/t/issue-with-cloudflare-template/35113/1 "2015-10-30T17:52:00Z")

</div>

Recent rebuilds with Cloudflare support enabled through the official template result in an erroneous line appearing in /etc/nginx/conf.d/discourse.conf:

```
set_real_ip_from 103.21.244.0/22;
set_real_ip_from 103.22.200.0/22;
set_real_ip_from 103.31.4.0/22;
set_real_ip_from 104.16.0.0/12;
set_real_ip_from 108.162.192.0/18;
set_real_ip_from 141.101.64.0/18;
set_real_ip_from 162.158.0.0/15;
set_real_ip_from 172.64.0.0/13;
set_real_ip_from 173.245.48.0/20;
set_real_ip_from 188.114.96.0/20;
set_real_ip_from 190.93.240.0/20;
set_real_ip_from 197.234.240.0/22;
set_real_ip_from 198.41.128.0/17;
set_real_ip_from 199.27.128.0/21;
set_real_ip_from ;
set_real_ip_from 2400:cb00::/32;
set_real_ip_from 2405:8100::/32;
set_real_ip_from 2405:b500::/32;
set_real_ip_from 2606:4700::/32;
set_real_ip_from 2803:f800::/32;

```

The result is that the Discourse instance becomes unavailable, with the production.log flooded by:

```
invalid number of arguments in "set_real_ip_from" directive in /etc/nginx/conf.d/discourse.conf

```

Commenting out the line immediately resolves the issue.

Has the source data at Cloudflare changed? At the minimum it looks like they might be sending a blank row that will need trimming to avoid recurrences of this issue.

---

_[View the full topic](https://meta.discourse.org/t/issue-with-cloudflare-template/35113)._
