title: What is actual ways Nginx purge cache with wildcard HTTP request?
body: <p>First of all I searching and trying some articles:</p>
  
  <p><strong>1)</strong> <a href="https://www.ryadel.com/en/nginx-purge-proxy-cache-delete-invalidate-linux-centos-7/" rel="nofollow noreferrer">https://www.ryadel.com/en/nginx-purge-proxy-cache-delete-invalidate-linux-centos-7/</a></p>
  
  <p>In the first way:</p>
  
  <p>a) update cache by curl request (BYPASS), it works for me, but there is no example for updating cache by wildcard</p>
  
  <p>b) deleting the cache by curl request with the PURGE method, using the outdated module ngx_cache_purge-2.3, but there is no example for updating the cache on the wildcard, and at least configured as shown in the article does not work for me (nginx 1.14):</p>
  
  <blockquote>
    <p>curl -X PURGE -I mysite.com/text.txt</p>
    
    <p>curl: (52) Empty reply from server</p>
  </blockquote>
  
  <p><strong>2)</strong> <a href="https://scene-si.org/2016/11/02/purging-cached-items-from-nginx-with-lua/" rel="nofollow noreferrer">https://scene-si.org/2016/11/02/purging-cached-items-from-nginx-with-lua/</a>;
  <a href="https://gist.github.com/titpetric/2f142e89eaa0f36ba4e4383b16d61474/revisions" rel="nofollow noreferrer">https://gist.github.com/titpetric/2f142e89eaa0f36ba4e4383b16d61474/revisions</a></p>
  
  <p>In the second way:</p>
  
  <p>If I understand correctly, lua requires nginx version 1.10, and mine is v1.14 and there is no lua module for v.1.14.</p>
  
  <blockquote>
    <p>nginx: [emerg] module "/usr/lib64/nginx/modules/ngx_http_lua_module.so" version 1010001 instead of 1014000 in /etc/nginx/nginx.conf:1</p>
  </blockquote>
  
  <p><strong>So my question is:</strong> is there working way for <strong>Nginx v1.14</strong> purge cache <strong>with wildcard</strong> HTTP request that You can advice?</p>
  
  <p>Best regards</p>