修复 HTTPS 资源链接生成

This commit is contained in:
2026-04-19 15:15:58 +08:00
parent 438241e878
commit 900c93c6c7
4 changed files with 55 additions and 0 deletions
+13
View File
@@ -54,6 +54,19 @@ return [
'url' => env('APP_URL', 'http://localhost'),
/*
|--------------------------------------------------------------------------
| Force HTTPS
|--------------------------------------------------------------------------
|
| 某些生产环境会经过 Nginx / CDN / 面板反向代理,应用层未必总能正确识别
| 原始 HTTPS 协议。开启后会强制所有通过 URL / asset / @vite 生成的资源
| 使用 https 方案,避免后台页面出现 Mixed Content。
|
*/
'force_https' => (bool) env('APP_FORCE_HTTPS', false),
/*
|--------------------------------------------------------------------------
| Trusted Proxies