我的nginx错误日志中出现错误。我试图通过添加一个名为.ebextensions的文件夹并添加一个名为01_files.config的文件来增加文件大小。与http {}有关,我不确定如何更新此文件以使其工作!谢谢!
在我的01_files.config
中files:
"/etc/nginx/conf.d/proxy.conf" :
mode: "000755"
owner: root
group: root
content: |
http {
client_max_body_size 20M;
}
service nginx reload
image.config “位于.ebextensions文件夹”
packages:
yum:
ImageMagick-devel: []
2016/06/05 03:23:01 [emerg] 6587#0: "http" directive is not allowed here in /etc/nginx/conf.d/proxy.conf:1
/var/log/nginx/error.log-20160605
[error] 2818#0: *19636 client intended to send too large body: 2771652 bytes, client: 172.31.24.171, server: _, request: "POST / HTTP/1.1", host:
答案 0 :(得分:0)
如果删除周围的http和reload指令,这应该可以工作,如下所示:
files:
"/etc/nginx/conf.d/proxy.conf" :
mode: "000755"
owner: root
group: root
content: |
client_max_body_size 20M;