123456789101112131415161718192021222324252627282930313233343536373839404142 |
- server {
- listen 80;
- listen [::]:80;
- access_log /data/wwwlogs/www.takegpt.cn_nginx.log combined;
- location / {
- proxy_pass https://api.openai.com;
- proxy_ssl_server_name on;
- proxy_set_header Host api.openai.com;
- chunked_transfer_encoding off;
- proxy_buffering off;
- proxy_cache off;
-
-
- }
- }
- server {
- listen 443 ssl http2;
- listen [::]:443 ssl http2;
-
- ssl_certificate "/root/.acme.sh/takegpt.cn_ecc/fullchain.cer";
- ssl_certificate_key "/root/.acme.sh/takegpt.cn_ecc/takegpt.cn.key";
- ssl_session_cache shared:SSL:1m;
- ssl_session_timeout 10m;
- ssl_ciphers HIGH:!aNULL:!MD5;
- ssl_prefer_server_ciphers on;
- location / {
- proxy_pass https://api.openai.com;
- }
-
- error_page 404 /404.html;
- location = /40x.html {
- }
- error_page 500 502 503 504 /50x.html;
- location = /50x.html {
- }
- }
|