nginx_cache_multipurge icon indicating copy to clipboard operation
nginx_cache_multipurge copied to clipboard

how we can use it with token ?

Open noway75 opened this issue 3 years ago • 0 comments

Hi,

I've tried with first example and it's work fine but with second example, cache does not clear.

`#cat /etc/nginx/conf.d/method_map.conf

map $cookie_purge_token $purge_cache { default 0; b04f01fc92094bcc43d1cb78adc7836e 1; } `

` location /cache/purge {

set $cmp_run_if $purge_cache; set $cmp_cache_key $scheme$host$uri$is_args$args; set $cmp_cache_path "/var/www/nginxcache/"; set $cmp_cache_strip "/cache/purge/"; content_by_lua_file /etc/nginx/lua/cache_multipurge.lua; } `

` curl -I "http://localhost/cache/purge/*" -H "Authorization: Bearer

b04f01fc92094bcc43d1cb78adc7836e" HTTP/1.1 200 OK Date: Thu, 21 Jan 2021 16:01:57 GMT Content-Type: application/octet-stream Connection: keep-alive

`

I forgot something ? thanks.

noway75 avatar Jan 21 '21 16:01 noway75