Files
resty_functions/prod/upload
木逸辰 c7a35c4744 add combine image logic (#14)
* add combine image logic

* remove unnecessary log
2021-09-06 18:56:59 +08:00
..
2021-09-06 18:56:59 +08:00
2021-08-28 22:01:00 +08:00
2021-09-06 18:56:59 +08:00

put upload.lua into:

/usr/local/opt/openresty/nginx/resty_funcs

post file:

$ curl --location --request POST 'localhost/upload' \
--form '=@"/Users/weli/works/task_server/src/test/resources/file_example_JPG_100kB.jpeg"'

nginx config

/usr/local/etc/openresty/nginx.conf
location /upload {
   content_by_lua_file /usr/local/opt/openresty/nginx/resty_funcs/upload.lua;
}

enable log:

error_log  /usr/local/etc/openresty/logs/error.log;