nginx rewrite regex min,max repetition
<p>I am using this rewrite in NGINX. <br>
<code>rewrite ^/test[^a-zA-Z0-9]{2}/?$ https://www.google.com permanent; // doesn't work</code></p>

<p>The server fails to start with I add the <code>min {2}</code> repetition in the regex. The server comes up when I remove that like here: <br> <code>rewrite ^/test[^a-zA-Z0-9]/?$ https://www.google.com permanent; // this works</code> <br></p>

<p>I have tried both <code>{min,max}</code> params.
The error that I get when I use the <code>min</code> repetition is as below. <br>
<code>directive "rewrite" is not terminated by ";"</code></p>

<p>The context of this rewrite is <code>server</code>.</p>

<p>Can someone tell if what am I missing? Is there some module that need to be installed for this to work?<br>
My prod NGINX version is 1.4 and I tried it on my local with 1.10.</p>