# 테마 구성 요소를 추가하거나 제거한 후 사용자 설정 페이지가 업데이트되지 않음: CDN 캐시 문제?

**URL:** https://meta.discourse.org/t/user-settings-page-not-updated-after-adding-or-removing-a-theme-component-cache-issue-with-cdn/165227
**Category:** Self-hosting
**Tags:** cdn
**Created:** [9월 24, 2020, 1:53오후 UTC](https://meta.discourse.org/t/user-settings-page-not-updated-after-adding-or-removing-a-theme-component-cache-issue-with-cdn/165227 "2020-09-24T13:53:21Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![Canapin](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/canapin/32/119591_2.png) [@Canapin](https://meta.discourse.org/u/Canapin)
#### Post date: [9월 24, 2020, 1:53오후 UTC](https://meta.discourse.org/t/user-settings-page-not-updated-after-adding-or-removing-a-theme-component-cache-issue-with-cdn/165227/1 "2020-09-24T13:53:21Z")

</div>

안녕하세요,

현재 기본 테마에 테마 구성 요소를 추가하거나 제거하면 사용자 설정이 그에 따라 업데이트되지 않습니다(제 구성 요소 중 하나가 사용자 설정 입력 필드를 추가합니다).

해당 입력 필드가 추가(또는 제거)되려면 CDN 캐시를 비워야 합니다.  
잘못된 캐시된 사용자 설정 페이지가 존재하면 사용자가 일부 설정을 변경하려고 할 때 403 오류가 발생합니다.

이 문제는 관리자 계정에는 영향을 주지 않지만, 테스트 목적으로 생성한 일반 사용자 계정에서는 발생합니다.

이 문제를 해결할 방법이 있을까요?

제 CDN 설정은 다음과 같습니다:

 ![image](https://global.discourse-cdn.com/meta/original/3X/0/8/080d7e6fdebd258fd81b9d87df5aa958c7da34cf.png)

 ![image](https://global.discourse-cdn.com/meta/original/3X/1/1/11726ed634aebff500b15a3669c87e1bc94924bf.png)

제 Discourse는 표준 설치 환경입니다.

---

<div class="post-metadata">

### Author: ![Falco](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/falco/32/179432_2.png) [@Falco](https://meta.discourse.org/u/Falco)
#### Post date: [9월 24, 2020, 2:19오후 UTC](https://meta.discourse.org/t/user-settings-page-not-updated-after-adding-or-removing-a-theme-component-cache-issue-with-cdn/165227/2 "2020-09-24T14:19:17Z")

</div>

여기에 app.yml 설정을 추가해 주세요. 설정 오류로 인해 도메인 전체가 CDN 뒤에 있는 것으로 보이므로, 이러한 오류는 예상되는 것입니다.

---

<div class="post-metadata">

### Author: ![Canapin](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/canapin/32/119591_2.png) [@Canapin](https://meta.discourse.org/u/Canapin)
#### Post date: [9월 24, 2020, 2:41오후 UTC](https://meta.discourse.org/t/user-settings-page-not-updated-after-adding-or-removing-a-theme-component-cache-issue-with-cdn/165227/3 "2020-09-24T14:41:31Z")

</div>

안녕하세요, 답변 주셔서 감사합니다.  
제 `app.yml` 파일은 다음과 같습니다:

```plaintext
## this is the all-in-one, standalone Discourse Docker container template
##
## After making changes to this file, you MUST rebuild
## /var/discourse/launcher rebuild app
##
## BE *VERY* CAREFUL WHEN EDITING!
## YAML FILES ARE SUPER SUPER SENSITIVE TO MISTAKES IN WHITESPACE OR ALIGNMENT!
## visit http://www.yamllint.com/ to validate this file as needed

templates:
  - "templates/postgres.template.yml"
  - "templates/redis.template.yml"
  - "templates/web.template.yml"
  - "templates/web.ratelimited.template.yml"
## Uncomment these two lines if you wish to add Lets Encrypt (https)
  - "templates/web.ssl.template.yml"
  - "templates/web.letsencrypt.ssl.template.yml"

## which TCP/IP ports should this container expose?
## If you want Discourse to share a port with another webserver like Apache or nginx,
## see https://meta.discourse.org/t/17247 for details
expose:
  - "80:80" # http
  - "443:443" # https

params:
  db_default_text_search_config: "pg_catalog.english"

  ## Set db_shared_buffers to a max of 25% of the total memory.
  ## will be set automatically by bootstrap based on detected RAM, or you can override
  db_shared_buffers: "2048MB"

  ## can improve sorting performance, but adds memory usage per-connection
  #db_work_mem: "40MB"

  ## Which Git revision should this container use? (default: tests-passed)
  #version: tests-passed

env:
  LANG: en_US.UTF-8
  # DISCOURSE_DEFAULT_LOCALE: en

  ## How many concurrent web requests are supported? Depends on memory and CPU cores.
  ## will be set automatically by bootstrap based on detected CPUs, or you can override
  UNICORN_WORKERS: 8

  ## TODO: The domain name this Discourse instance will respond to
  ## Required. Discourse will not work with a bare IP number.
  DISCOURSE_HOSTNAME: unicyclist.com

  ## Uncomment if you want the container to be started with the same
  ## hostname (-h option) as specified above (default "$hostname-$config")
  #DOCKER_USE_HOSTNAME: true

  ## TODO: List of comma delimited emails that will be made admin and developer
  ## on initial signup example 'user1@example.com,user2@example.com'
  DISCOURSE_DEVELOPER_EMAILS: 'canapin@gmail.com'

  ## TODO: The SMTP mail server used to validate new accounts and send notifications
  # SMTP ADDRESS, username, and password are required
  # WARNING the char '#' in SMTP password can cause problems!
  DISCOURSE_SMTP_ADDRESS: smtp.gmail.com
  DISCOURSE_SMTP_PORT: 587
  DISCOURSE_SMTP_USER_NAME: no-reply@email.unicyclist.com
  DISCOURSE_SMTP_PASSWORD: xxx
  #DISCOURSE_SMTP_ENABLE_START_TLS: true # (optional, default true)

  ## If you added the Lets Encrypt template, uncomment below to get a free SSL certificate
  LETSENCRYPT_ACCOUNT_EMAIL: me@example.com

  ## The http or https CDN address for this Discourse instance (configured to pull)
  ## see https://meta.discourse.org/t/14857 for details
  DISCOURSE_CDN_URL: https://f5i4i8k5.stackpathcdn.com

## The Docker container is stateless; all data is stored in /shared
volumes:
  - volume:
      host: /var/discourse/shared/standalone
      guest: /shared
  - volume:
      host: /var/discourse/shared/standalone/log/var-log
      guest: /var/log

## Plugins go here
## see https://meta.discourse.org/t/19157 for details
hooks:
  after_code:
    - exec:
        cd: $home/plugins
        cmd:
          - git clone https://github.com/discourse/docker_manager.git
          - git clone https://github.com/discourse/discourse-data-explorer.git
          - git clone https://github.com/paviliondev/discourse-locations
          - git clone https://github.com/davidtaylorhq/discourse-whos-online

## Any custom commands to run after building
run:
  - exec: echo "Beginning of custom commands"
  ## If you want to set the 'From' email address for your first registration, uncomment and change:
  ## After getting the first signup email, re-comment the line. It only needs to run once.
  #- exec: rails r "SiteSetting.notification_email='info@unconfigured.discourse.org'"
  - exec: echo "End of custom commands"

```

---

<div class="post-metadata">

### Author: ![Falco](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/falco/32/179432_2.png) [@Falco](https://meta.discourse.org/u/Falco)
#### Post date: [9월 24, 2020, 2:45오후 UTC](https://meta.discourse.org/t/user-settings-page-not-updated-after-adding-or-removing-a-theme-component-cache-issue-with-cdn/165227/4 "2020-09-24T14:45:22Z")

</div>

DNS 설정이 잘못되었습니다.

`unicyclist.com`은 VPS의 IP를 가리키는 `A` 레코드로 설정되어야 하지만, 현재 StackPath IP를 가리키고 있습니다.

---

<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: [10월 24, 2020, 2:45오후 UTC](https://meta.discourse.org/t/user-settings-page-not-updated-after-adding-or-removing-a-theme-component-cache-issue-with-cdn/165227/5 "2020-10-24T14:45:49Z")

</div>

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