Skip to content

Commit

Permalink
增加一处使用宝塔面板时应该修改的配置文件 (#345)
Browse files Browse the repository at this point in the history
  • Loading branch information
weirui-kong authored May 26, 2024
1 parent 64ad22c commit 59af80b
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
6 changes: 6 additions & 0 deletions docs/guide/install/reverse-proxy.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,12 @@ If you use the bt.cn, be sure to delete the following default configuration
:::


Disable Nginx caching in `/www/server/nginx/conf/proxy.conf` or the corresponding website configuration file. Otherwise, with the default configuration, when accessing large files, Nginx will attempt to cache the remote file locally first, resulting in playback failures.
```conf
proxy_cache cache_one; # Remove this line
proxy_max_temp_file_size 0; # Add this line
```

### **Apache**
Add the anti-generation configuration item ProxyPass under the VirtualHost field, such as:
```xml
Expand Down
7 changes: 7 additions & 0 deletions docs/zh/guide/install/reverse-proxy.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,13 @@ proxy_set_header Host $host:$server_port;
- location ~ .\*\.(js|css)?$
```

并在`/www/server/nginx/conf/proxy.conf`中或对应网站配置文件中设置禁用Nginx缓存,否则默认配置下访问较大文件时Nginx会先尝试将远程文件缓存至本机,导致播放失败

```conf
proxy_cache cache_one; # 删除这一行
proxy_max_temp_file_size 0; #加上这一行
```

:::

## **Apache**
Expand Down

0 comments on commit 59af80b

Please sign in to comment.