k8s ingress 配置问题
1、文件太大413:Request Entity Too Largemetadata:annotations:nginx.ingress.kubernetes.io/proxy-body-size: 1024m2、上传超时504:Gateway Timeoutmetadata:annotations:nginx.ingress.kubernetes.io/proxy-read-timeout: "
·
1、文件太大
413:Request Entity Too Large
metadata: annotations: nginx.ingress.kubernetes.io/proxy-body-size: 1024m
2、上传超时
504:Gateway Timeout
metadata: annotations: nginx.ingress.kubernetes.io/proxy-read-timeout: "600" nginx.ingress.kubernetes.io/proxy-send-timeout: "600" nginx.ingress.kubernetes.io/proxy_connect_timeout: "600"
3、Nginx常用配置
apiVersion: extensions/v1beta1 kind: Ingress metadata: name: ingress-dt annotations: kubernetes.io/ingress.class: "nginx" nginx.ingress.kubernetes.io/configuration-snippet: | proxy_set_header Upgrade $http_upgrade; proxy_http_version 1.1; proxy_set_header X-Forwarded-Host $http_host; proxy_set_header X-Forwarded-Proto $scheme; proxy_set_header X-Forwarded-For $remote_addr; proxy_set_header Host $host; proxy_set_header Connection "upgrade"; proxy_cache_bypass $http_upgrade;
k8s参考资料 :https://kubernetes.github.io/ingress-nginx/user-guide/nginx-configuration/annotations/
更多推荐
已为社区贡献1条内容
所有评论(0)