Welcome! Log In Create A New Profile

Advanced

Nginx http module putting config in NGX_MAIN_CONF

March 20, 2012 07:54AM
hi,
I want to put variable inside nginx NGX_MAIN_CONF

I want written code like this

{ ngx_string("mydata"),
NGX_MAIN_CONF|NGX_DIRECT_CONF|NGX_CONF_TAKE1,
ngx_conf_set_str_slot,
0,
offsetof(ngx_http_my_main_conf_t, my_data),
NULL },


But when I put in in configuration file
worker_processes 2;
mydata "a";

I am getting following error
nginx: [emerg] unknown directive "mydata"

How to fix this ?


regards
Vivek Goel
_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel
Subject Author Views Posted

Nginx http module putting config in NGX_MAIN_CONF

goelviek2011@gmail.com 1881 March 20, 2012 07:54AM

Re: Nginx http module putting config in NGX_MAIN_CONF

Maxim Dounin 771 March 20, 2012 08:54AM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 115
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready