Closed artembokhan closed 4 years ago
I think you must have messed something up in the config, because I'm using such a solution in one of my apps and it's working fine (different sources for the IP to be geolocated, variable set in the main file, geoip2 directives loaded from conf.d/
)
I have a workaround using variable $http_variable (aka request header) which is working but not with $variable
Variable must be defined to use it. I was trying to use variable from named capture group which did not work.
@wronan can you please show me the content of your configuration file from conf.d
?
Sorry man... I've switched to other solution long time ago and the config is gone.
If variable is defined inside configuration file it can't be used as source. Please fix if possible.
nginx -t nginx: [emerg] unknown "ipaddress" variable nginx: configuration file /etc/nginx/nginx.conf test failed