> For the complete documentation index, see [llms.txt](https://ayakaleaf-pro.ayaka.space/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://ayakaleaf-pro.ayaka.space/on-premises/zh-tw/she-ding/overleaf-toolkit/toolkit-settings.md).

# Toolkit 設定

本頁說明在……中支援的環境變數 `config/overleaf.rc` 供 Toolkit 部署使用的檔案。

該 `config/overleaf.rc` 檔案包含格式如下的變數定義 `NAME=value`。以……開頭的行 `#` 開頭的行會被視為註解。

{% hint style="info" %}
在變更任何 `overleaf.rc` 或 `variables.env` 之後，請執行 `bin/up`.
{% endhint %}

## 容器

### `sharelatex`

| 名稱                           | 說明                                                                                                                                                                                                                                                                                                             |
| ---------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `PROJECT_NAME`               | <p>設定……的值 <code>--project-name</code> 旗標，提供給 <code>docker-compose</code>。這在於同一主機上執行多個 Overleaf 執行個體時很有用，因為每個執行個體都可以有不同的專案名稱。<br><br>- <strong>預設</strong>: <code>overleaf</code></p>                                                                                                                           |
| `OVERLEAF_IMAGE_NAME`        | <p>Server Pro/CE 應用程式容器所使用的 Docker 映像。這只是 Docker 映像名稱；Docker 映像標籤取自 <code>config/version</code>.<br><br>- <strong>預設：</strong><br>- Server Pro: <code>quay.io/sharelatex/sharelatex-pro</code><br>- 社群版： <code>sharelatex/sharelatex</code></p>                                                                |
| `SERVER_PRO`                 | <p>當設定為 <code>true</code>，會告訴 Toolkit 使用 Server Pro 映像（<code>quay.io/sharelatex/sharelatex-pro</code>），而不是預設的 Server CE 映像（<code>sharelatex/sharelatex</code>).<br><br>- <strong>預設</strong>: <code>false</code></p>                                                                                           |
| `GIT_BRIDGE_ENABLED`         | <p>設定為 <code>true</code> 以啟用 git-bridge 功能（僅限 Server Pro）。更多資訊請參閱 <a href="https://www.overleaf.com/learn/how-to/Git_integration"><https://www.overleaf.com/learn/how-to/Git_integration></a> 使用者文件。<br><br>- <strong>預設：</strong> <code>false</code></p>                                                      |
| `GIT_BRIDGE_IMAGE`           | <p>git-bridge 容器所使用的 Docker 映像（僅限 Server Pro）。這只是 Docker 映像名稱；Docker 映像標籤取自 <code>config/version</code>.<br><br>- <strong>預設：</strong> <code>quay.io/sharelatex/git-bridge</code></p>                                                                                                                          |
| `GIT_BRIDGE_DATA_PATH`       | 設定將會掛載到 `git-bridge` 容器（僅限 Server Pro），並用來儲存 git-repositories。這可以是完整路徑（以 `/`），或是相對於 Toolkit 基礎目錄的相對路徑。                                                                                                                                                                                                         |
| `GIT_BRIDGE_LOG_LEVEL`       | <p>設定 <code>git-bridge</code> 容器的記錄層級。可用等級： <code>TRACE</code>, <code>DEBUG</code>, <code>INFO</code>, <code>WARN</code>, <code>ERROR</code>.<br><br>- <strong>預設：</strong> <code>INFO</code></p>                                                                                                              |
| `SIBLING_CONTAINERS_ENABLED` | <p>當設定為 <code>true</code>，會告訴 Toolkit 使用 <strong>Sibling Containers</strong> 技術，將專案在彼此獨立的沙箱中編譯，每個專案使用獨立的 Docker 容器。更多資訊請參閱 \<server-pro-only-configuration/sandboxed-compiles> 文件。<br><br>- <strong>需要：</strong> <code>SERVER\_PRO=true</code><br>- <strong>預設：</strong> <code>true</code></p>                 |
| `SIBLING_CONTAINERS_PULL`    | <p>當設定為 <code>true</code>，會告訴 Toolkit 自動拉取所有使用 <code>ALL\_TEX\_LIVE\_DOCKER\_IMAGES</code> 在 <strong>config/variables.env</strong> 在使用 <code>bin/up</code> 命令時的檔案。<br><br>- <strong>預設：</strong> <code>true</code></p>                                                                                         |
| `DOCKER_SOCKET_PATH`         | <p>設定主機機器（執行 Toolkit 的機器）上 Docker socket 的路徑。當 <code>SIBLING\_CONTAINERS\_ENABLED</code> 為 <code>true</code>時，該 socket 將會掛載到容器中，以允許編譯器服務在主機上建立新的 Docker 容器。<br><br>- <strong>需要：</strong> <code>SIBLING\_CONTAINERS\_ENABLED=true</code><br>- <strong>預設：</strong> <code>/var/run/docker.sock</code></p>       |
| `OVERLEAF_DATA_PATH`         | <p>設定將會掛載到主要 <code>sharelatex</code> 容器，並用來儲存編譯資料。這可以是完整路徑（以 <code>/</code>），或是相對於 Toolkit 基礎目錄的相對路徑。<br><br>- <strong>預設：</strong> <code>data/overleaf</code></p>                                                                                                                                             |
| `OVERLEAF_LISTEN_IP`         | <p>設定容器將繫結的主機 IP 位址。例如，如果這設為 <code>0.0.0.0</code>，那麼網頁介面將可透過任何主機 IP 位址存取。若要直接存取容器，……的值必須設為你的公開 IP 位址。 <code>OVERLEAF\_LISTEN\_IP</code> 必須設為你的公開 IP 位址。將 <code>OVERLEAF\_LISTEN\_IP</code> 為以下任一值 <code>0.0.0.0</code> 或你的主機外部 IP 通常會在與上述設定一併使用時導致錯誤。<br><br>- <strong>預設：</strong> <code>127.0.0.1</code></p> |
| `OVERLEAF_PORT`              | <p>設定容器將繫結的主機連接埠。例如，如果這設為 <code>8099</code> 以及 <code>OVERLEAF\_LISTEN\_IP</code> 設為 <code>127.0.0.1</code>，那麼網頁介面將可透過 <code><http://localhost:8099></code>.<br><br>- <strong>預設：</strong> <code>80</code></p>                                                                                                  |
| `OVERLEAF_LOG_PATH`          | <p>設定將會掛載到主要 <code>sharelatex</code> 容器，並用來讓應用程式記錄可在 Docker 主機上存取。這可以是完整路徑（以 <code>/</code>），或是相對於 Toolkit 基礎目錄的相對路徑。移除設定項目即可停用繫結掛載。若未設定，重建容器時記錄檔將會被丟棄。<br><br>請參閱有關記錄的資訊。<br><br>- <strong>預設：</strong> 未設定</p>                                                                                               |

***

### `mongo`

| 名稱                | 說明                                                                                                                                                                                                                                                      |
| ----------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `MONGO_ENABLED`   | <p>當設定為 <code>true</code>，會告訴 Toolkit 建立一個 MongoDB 容器來主控資料庫。當設為 <code>false</code>時，不會建立此容器，而系統將改用由……指定的 MongoDB 資料庫 <code>MONGO\_URL</code> 。<br><br>- <strong>預設</strong>: <code>true</code></p>                                                      |
| `MONGO_URL`       | <p>指定在……時要使用的 MongoDB 連線 URL <code>MONGO\_ENABLED</code> 為 <code>false</code>.<br><br>- <strong>預設</strong>：未設定</p>                                                                                                                                     |
| `MONGO_DATA_PATH` | <p>設定將會掛載到 <code>mongo</code> 容器，並用來儲存 MongoDB 資料庫。這可以是完整路徑（以 <code>/</code>），或是相對於 toolkit 基礎目錄的相對路徑。此選項只會影響本機 <code>mongo</code> 在……時建立的容器 <code>MONGO\_ENABLED</code> 為 <code>true</code>.<br><br>- <strong>預設</strong>: <code>data/mongo</code></p> |
| `MONGO_IMAGE`     | <p>MongoDB 容器所使用的 Docker 映像。這只是 Docker 映像名稱；Docker 映像標籤應填入 <code>MONGO\_VERSION</code> （見下文）。<br><br>- <strong>預設：</strong> <code>mongo</code></p>                                                                                                      |
| `MONGO_VERSION`   | <p>MongoDB 容器所使用的 MongoDB 版本。其值必須以 MongoDB 的主要版本號和一個點開頭，例如 <code>6.0</code> 或 <code>6.0-with-suffix</code>.<br><br>- <strong>預設：</strong> <code>6.0</code></p>                                                                                          |

***

### `redis`

| 名稱                      | 說明                                                                                                                                                                                                                                                    |
| ----------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `REDIS_ENABLED`         | <p>當設定為 <code>true</code>，會告訴 Toolkit 建立一個 Redis 容器來主控 redis 資料庫。當設為 <code>false</code>時，不會建立此容器，而系統將改用由……指定的 Redis 資料庫 <code>REDIS\_HOST</code> 以及 <code>REDIS\_PORT</code> 。<br><br>- <strong>預設</strong>: <code>true</code></p>                    |
| `REDIS_HOST`            | <p>指定在……時要使用的 Redis 主機 <code>REDIS\_ENABLED</code> 為 <code>false</code>.<br><br>- <strong>預設</strong>：未設定</p>                                                                                                                                         |
| `REDIS_PORT`            | <p>指定在……時要使用的 Redis 連接埠 <code>REDIS\_ENABLED</code> 為 <code>false</code>.<br><br>- <strong>預設</strong>：未設定</p>                                                                                                                                        |
| `REDIS_DATA_PATH`       | <p>設定將會掛載到 <code>redis</code> 容器，並用來儲存 Redis 資料庫。這可以是完整路徑（以 <code>/</code>），或是相對於 Toolkit 基礎目錄的相對路徑。此選項只會影響本機 <code>redis</code> 在……時建立的容器 <code>REDIS\_ENABLED</code> 為 <code>true</code>.<br><br>- <strong>預設</strong>: <code>data/redis</code></p> |
| `REDIS_AOF_PERSISTENCE` | <p>為 Redis 開啟 AOF（Append Only File）持久化。這是 <strong>建議</strong> 的 Redis 持久化設定。更多詳細資訊，請參閱 <../../../maintenance/data-and-backups#aof-append-only-file> 中的 <../../maintenance/data-and-backups> 區段。<br><br>- <strong>預設：</strong> <code>true</code></p>   |

***

### `nginx`

| 名稱                     | 說明                                                                                                                                                                                                                                                                                         |
| ---------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `NGINX_ENABLED`        | <p>當設定為 <code>true</code>，會告訴 Toolkit 建立一個 NGINX 容器作為 TLS Proxy。<br><br>- <strong>預設</strong>: <code>false</code></p>                                                                                                                                                                      |
| `NGINX_CONFIG_PATH`    | <p>供 TLS Proxy 使用的 NGINX 設定檔路徑。<br><br>- <strong>預設</strong>: <code>config/nginx/nginx.conf</code></p>                                                                                                                                                                                     |
| `NGINX_TLS_LISTEN_IP`  | <p>設定 TLS Proxy 容器將繫結的主機 IP 位址以供 HTTPS 使用。例如，如果這設為 <code>0.0.0.0</code> 那麼 HTTPS 網頁介面將可透過任何主機 IP 位址存取。通常這應設為你主機的外部 IP。<br><br>- <strong>預設</strong>: <code>127.0.1.1</code></p>                                                                                                            |
| `NGINX_HTTP_LISTEN_IP` | <p>設定 TLS Proxy 容器將繫結的主機 IP 位址以供 HTTP 重新導向。例如，如果這設為 <code>127.0.1.1</code> 那麼對……的 HTTP 連線將會重新導向至 <code>127.0.1.1</code> HTTPS 網頁介面。通常這應設為你主機的外部 IP。請不要將其設為 <code>0.0.0.0</code> ，因為這通常會與……發生衝突 <code>OVERLEAF\_LISTEN\_IP</code>.<br><br>- <strong>預設</strong>: <code>127.0.1.1</code></p> |
| `NGINX_HTTP_PORT`      | <p>設定 TLS Proxy 容器將繫結的主機連接埠以供 HTTP 使用。<br><br>- <strong>預設</strong>: <code>80</code></p>                                                                                                                                                                                                   |
| `TLS_PORT`             | <p>設定 TLS Proxy 容器將繫結的主機連接埠以供 HTTPS 使用。<br><br>- <strong>預設</strong>: <code>443</code></p>                                                                                                                                                                                                 |
| `TLS_PRIVATE_KEY_PATH` | <p>供 TLS Proxy 使用的私鑰路徑。<br><br>- <strong>預設</strong>: <code>config/nginx/certs/overleaf\_key.pem</code></p>                                                                                                                                                                                |
| `TLS_CERTIFICATE_PATH` | <p>供 TLS Proxy 使用的公開憑證路徑。<br><br>- <strong>預設</strong>: <code>config/nginx/certs/overleaf\_certificate.pem</code></p>                                                                                                                                                                      |


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://ayakaleaf-pro.ayaka.space/on-premises/zh-tw/she-ding/overleaf-toolkit/toolkit-settings.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
