# discourse.conf 파일은 어디에 있나요?

**URL:** https://meta.discourse.org/t/where-is-the-discourse-conf-file/370705
**Category:** Self-hosting
**Created:** [6월 18, 2025, 3:00오후 UTC](https://meta.discourse.org/t/where-is-the-discourse-conf-file/370705 "2025-06-18T15:00:48Z")
**Posts on this page:** 12
**Page:** 1

<div class="post-metadata">

### Author: ![agemo](https://avatars.discourse-cdn.com/v4/letter/a/ac91a4/32.png) [@agemo](https://meta.discourse.org/u/agemo)
#### Post date: [6월 18, 2025, 3:00오후 UTC](https://meta.discourse.org/t/where-is-the-discourse-conf-file/370705/1 "2025-06-18T15:00:48Z")

</div>

**`discourse.conf` 파일은 보통 어디에서 찾을 수 있나요?**

**discourse** 의 일반적인 설치 경로에 익숙하지 않아서요. 모든 것이 평소 완벽하게 작동하기 때문에 설정을 건드리지 않는 편입니다. - _미리 조언해 주시면 감사하겠습니다!_

이 질문에 대한 추가 배경 정보

> [@Discourse를 위한 Caddy와 Cloudflare 설정](https://meta.discourse.org/t/configuring-caddy-and-cloudflare-for-discourse/351563/6?u=agemo):
>
> Step 5: Configure Discourse to Use the SSL Certificate Edit the Discourse NGINX configuration to use the SSL certificate. Typically, this file is located at /etc/nginx/conf.d/discourse.conf or within the /var/discourse/containers/ directory if using Docker. Modify or add the following lines to the server block: [https://developer.tenten.co/discourse-with-cloudflare-ssl](https://developer.tenten.co/discourse-with-cloudflare-ssl) I am trying to setup CF origin server and I am stuck at this stage for the location of the discourse.conf file so I c…

---

<div class="post-metadata">

### Author: ![Lilly](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/lilly/32/575047_2.png) [@Lilly](https://meta.discourse.org/u/Lilly)
#### Post date: [6월 18, 2025, 3:13오후 UTC](https://meta.discourse.org/t/where-is-the-discourse-conf-file/370705/2 "2025-06-18T15:13:54Z")

</div>

이는 `discourse/config/` 디렉토리에 있어야 합니다:

> <https://github.com/discourse/discourse/blob/daa77feb7379a7507b6ceb5049114ad089a1dbf5/config/discourse_defaults.conf#L3>

---

<div class="post-metadata">

### Author: ![agemo](https://avatars.discourse-cdn.com/v4/letter/a/ac91a4/32.png) [@agemo](https://meta.discourse.org/u/agemo)
#### Post date: [6월 18, 2025, 3:16오후 UTC](https://meta.discourse.org/t/where-is-the-discourse-conf-file/370705/3 "2025-06-18T15:16:18Z")

</div>

고마워요. 그 위치는 봤는데, 앱을 실행해야 하죠?

앱 안에서 `nano`는 사용할 수 없어요. 거기서 무언가를 편집하려면 어떻게 해야 하나요?

---

<div class="post-metadata">

### Author: ![agemo](https://avatars.discourse-cdn.com/v4/letter/a/ac91a4/32.png) [@agemo](https://meta.discourse.org/u/agemo)
#### Post date: [6월 18, 2025, 3:31오후 UTC](https://meta.discourse.org/t/where-is-the-discourse-conf-file/370705/4 "2025-06-18T15:31:14Z")

</div>

추가로 말씀드리면, 앱 안에서 이 내용을 볼 수 있고, 이것이 수정해야 할 부분이라고 생각합니다. 하지만 다시 한번, 앱 안에서 nano가 실행되지 않는 것 같아 어떻게 편집해야 할지 모르겠습니다. nano를 설치해야 하는 걸까요?

`…app:/etc/nginx/conf.d# discourse.conf`

---

<div class="post-metadata">

### Author: ![agemo](https://avatars.discourse-cdn.com/v4/letter/a/ac91a4/32.png) [@agemo](https://meta.discourse.org/u/agemo)
#### Post date: [6월 18, 2025, 3:32오후 UTC](https://meta.discourse.org/t/where-is-the-discourse-conf-file/370705/5 "2025-06-18T15:32:53Z")

</div>

그리고 만약 제가 그렇게 할 수 있다면(nano를 설치하고 .conf 파일을 편집하는 것), 업그레이드 시 해당 파일이 덮어쓰기될 것이라고 예상해야 할까요?

app.yml 파일에서 이 문제를 보완하기 위해 replace 명령을 사용할 수 있다는 언급을 확인했습니다([NGinx.conf File location](https://meta.discourse.org/t/nginx-conf-file-location/322162)). 하지만 제가 오해하고 있는 것 같고, 해당 링크가 예제에 연결되지 않는 매우 오래된 주제인 것 같습니다. 따라서 관련이 없을 수도 있습니다.

---

<div class="post-metadata">

### Author: ![Lilly](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/lilly/32/575047_2.png) [@Lilly](https://meta.discourse.org/u/Lilly)
#### Post date: [6월 18, 2025, 3:49오후 UTC](https://meta.discourse.org/t/where-is-the-discourse-conf-file/370705/6 "2025-06-18T15:49:23Z")

</div>

이것을 할 수 있어야 하지 않나요?

```plaintext
cd /var/www/discourse/config/
sudo nano discourse.conf

```

---

<div class="post-metadata">

### Author: ![agemo](https://avatars.discourse-cdn.com/v4/letter/a/ac91a4/32.png) [@agemo](https://meta.discourse.org/u/agemo)
#### Post date: [6월 18, 2025, 4:18오후 UTC](https://meta.discourse.org/t/where-is-the-discourse-conf-file/370705/7 "2025-06-18T16:18:01Z")

</div>

아니, 그런 파일이나 디렉터리가 존재하지 않습니다. (저는 앱 안에 있지 않아요)

---

<div class="post-metadata">

### Author: ![pangbo](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pangbo/32/538562_2.png) [@pangbo](https://meta.discourse.org/u/pangbo)
#### Post date: [6월 18, 2025, 4:41오후 UTC](https://meta.discourse.org/t/where-is-the-discourse-conf-file/370705/8 "2025-06-18T16:41:05Z")

</div>

> [@agemo](#):
>
> 앱 안에서 `nano`를 사용할 수 없어요.

컨테이너 내부에서 `apt install`을 사용해 nano를 설치할 수 있습니다.

또한 Nginx 설정 파일을 수정하려는 경우, 컨테이너 외부의 `app.yml`에서 수정하는 것이 권장됩니다.

---

<div class="post-metadata">

### Author: ![agemo](https://avatars.discourse-cdn.com/v4/letter/a/ac91a4/32.png) [@agemo](https://meta.discourse.org/u/agemo)
#### Post date: [6월 18, 2025, 5:12오후 UTC](https://meta.discourse.org/t/where-is-the-discourse-conf-file/370705/9 "2025-06-18T17:12:18Z")

</div>

예상대로입니다.

app.yml 파일에 어떻게 포맷해야 하나요? 메타 사이트에 관련 가이드가 있을까요?

다음 내용을 포함해야 합니다:

`ssl_certificate /etc/ssl/certs/cloudflare_origin.pem;`  
`ssl_certificate_key /etc/ssl/private/cloudflare_origin.key;`

---

<div class="post-metadata">

### Author: ![Lilly](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/lilly/32/575047_2.png) [@Lilly](https://meta.discourse.org/u/Lilly)
#### Post date: [6월 18, 2025, 7:43오후 UTC](https://meta.discourse.org/t/where-is-the-discourse-conf-file/370705/10 "2025-06-18T19:43:29Z")

</div>

고급 검색이 잘 작동합니다. #Documentation 카테고리에서 “app.yml”을 검색한 결과

[https://meta.discourse.org/t/set-environmental-variables/270832가](https://meta.discourse.org/t/set-environmental-variables/270832%EA%B0%80) 나왔습니다.

---

<div class="post-metadata">

### Author: ![pfaffman](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pfaffman/32/120154_2.png) [@pfaffman](https://meta.discourse.org/u/pfaffman)
#### Post date: [6월 19, 2025, 1:08오전 UTC](https://meta.discourse.org/t/where-is-the-discourse-conf-file/370705/11 "2025-06-19T01:08:23Z")

</div>

> [@agemo](#):
>
> `discourse.conf` 파일은 보통 어디에서 찾을 수 있나요?

컨테이너 안에 있습니다.

무엇을 하려 하시나요? 일반적으로 app.yml에서 환경 변수를 설정하여 구성합니다.

해결하려는 문제는 무엇인가요?

---

<div class="post-metadata">

### Author: ![agemo](https://avatars.discourse-cdn.com/v4/letter/a/ac91a4/32.png) [@agemo](https://meta.discourse.org/u/agemo)
#### Post date: [6월 19, 2025, 10:32오전 UTC](https://meta.discourse.org/t/where-is-the-discourse-conf-file/370705/12 "2025-06-19T10:32:44Z")

</div>

감사합니다.

처음에는 CF(클라우드플레어)를 통해 프록시할 때(과거에는 회색 구름 상태) SSL 설정이 Flexible에서 Full 또는 Full-Strict로 변경되면서 문제가 발생한 것 같다고 생각했습니다.

결국 그 문제는 아니었습니다. 메타의 가이드에 따르면 잘못된 CF SSL 설정으로 인해 발생할 수 있다고 언급된 심각한 리다이렉트 루프를 일으키던 오래된 페이지 규칙이 문제였습니다. 이 경우 그 골치 아픈 페이지 규칙 때문이었죠.

해결책 자체는 매우 쉬웠지만, 원인을 파악하는 데 시간이 좀 걸렸습니다! 😅

다만 부수적인 문제에 대해 말씀드리겠습니다.

Full [strict] 모드에서 키와 인증서를 설치할 때, CF Full [strict]의 경우 인증서와 키가 컨테이너 쪽에 배치되어야 한다고 가정하고 있습니다. app.yml 안의 .conf 유형 수정 사항도 마찬가지입니다.

이것은 제 기술적 이해도가 부족해서입니다. Docker는 초콜릿 달걀 같은 건가요? Linux가 초콜릿 달걀이고, Docker는 그 안에 있는 (이미 조립된) 멋진 장난감이라는 뜻입니다.

마지막으로, Discourse 설치에는 Let’s Encrypt가 포함되어 있었고, FULL 모드가 정상적으로 작동하는 것으로 보이며 HTTPS도 잘 작동합니다. 이로 인해 이제 트래픽 완화(미티게이션) 조치도 가능합니다.
