Closed joe94540712 closed 1 year ago
可以貼下你reverse proxy 的設定嗎? 我後來設定沒遇到問題了
可以貼下你 reverse proxy 的設定嗎?我後來設定沒遇到問題了
我是使用 nginx proxy manager設定的,並沒有特別調整什麼 但看起來 reverse proxy 部分應該沒問題才對(至少瀏覽器直接開啓網頁OK,要使用 Line webhook 時才出現Error)
server {
set $forward_scheme http;
set $server "SERVER_NAME";
set $port 3333;
listen 80;
listen [::]:80;
listen 443 ssl http2;
listen [::]:443 ssl http2;
server_name exmaple.domain;
# Block Exploits
include conf.d/include/block-exploits.conf;
# Force SSL
include conf.d/include/force-ssl.conf;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection $http_connection;
proxy_http_version 1.1;
access_log /logs/proxy-host-access.log proxy;
error_log /logs/proxy-host-error.log warn;
location / {
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection $http_connection;
proxy_http_version 1.1;
# Proxy!
include conf.d/include/proxy.conf;
}
# Custom
include /data/nginx/custom/server_proxy[.]conf;
}
還是 line 設定裡面的 key 有需要 "" or <> 的引號嗎?
LINE_CHANNEL_ACCESS_TOKEN=exampleTOKEN$@##@exampleTOKEN
LINE_CHANNEL_SECRET=exampleSECRET$@##@exampleTOKEN
還是 line 設定裡面的 key 有需要 "" or <> 的引號嗎?
LINE_CHANNEL_ACCESS_TOKEN=exampleTOKEN$@##@exampleTOKEN LINE_CHANNEL_SECRET=exampleSECRET$@##@exampleTOKEN
Key 不用引號,像你這樣輸入就可
你Nginx 得部份是跟docker在同一台server上嗎?
你 Nginx 得部份是跟 docker 在同一台 server 上嗎?
對的,都是在同一臺機器上,不過方便管理才使用docker做部署
你 Nginx 得部份是跟 docker 在同一台 server 上嗎?
對的,都是在同一臺機器上,不過方便管理才使用docker做部署
server {
listen 80;
server_name yourdomain;
return 301 https://yourdomain;
}
server {
listen 443 ssl;
server_name yourdomain;
ssl_certificate crt_file;
ssl_certificate_key key_file;
location / {
proxy_pass http://localhost:port;
proxy_pass_header Server;
proxy_set_header Host $http_host;
proxy_redirect off;
proxy_set_header X- Real - IP $remote_addr;
proxy_set_header X - Scheme $scheme;
proxy_set_header X - Forwarded - For $proxy_add_x_forwarded_for;
proxy_set_header X - Forwarded - Proto $scheme;
}
}
使用 4.4.4 版本,並透過 docker 進行部署 同時設定 reverse proxy 後,可於 https://example.domain 中可以正常顯示 "OK" 而在 https://example.domain/info中也正常顯示
{"currentVersion":"4.4.4","latestVersion":"4.4.4"}
不過在line後臺設定webhook時,https://example.domain/webhook 輸入完成驗證時,卻顯示下圖錯誤:
有檢查 .env 中 Line 的兩個參數皆輸入正確
其他 .env 中也僅設定 port & OpenAI API,其餘皆留白 有參考 #202 類似的問題,不過 @tsu299 遇到的 ERROR 爲 500 不知道還有哪部分有疏漏的地方嗎?