Hello!

On Thu, Dec 01, 2016 at 10:08:55AM -0800, Ya-wen Lin wrote:

> Thanks for your reply.
> I've already have
> load_module /usr/local/etc/nginx/ngx_http_my_module.so;
> in nginx.conf
> But that "ngx_http_my_module.so" will write out some files, I'd like to
> config the path for those generated files.
> Currently the path seems to be the working folder I start nginx service.

If you use paths in your module you are expected to handle them 
much like the nginx itself, depending on context:

- either relative to prefix, like load_module does;
- or relative to conf prefix, like include does;
- or relative to document root, like serving static files.

First two variants are usually handled at configuration parsing 
time using the ngx_conf_full_name() function.  Last one is usually 
done with the ngx_http_map_uri_to_path() function.

-- 
Maxim Dounin
http://nginx.org/

_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx

Reply via email to