You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by GitBox <gi...@apache.org> on 2021/07/26 06:16:13 UTC

[GitHub] [apisix] tzssangglass opened a new issue #4672: question: Proxy static files with APISIX, how to configure routes

tzssangglass opened a new issue #4672:
URL: https://github.com/apache/apisix/issues/4672


   Proxy static files with Nginx, for example:
   
   ```nginx
   location ~* .(js|css|flash|media|jpg|png|gif|ico|vbs|json|txt)$ {
   ...
   }
   ```
   
   In `nginx.conf`, this means matching requests with js, css, etc. as a suffix. This configuration can be converted into a route with regular matching for APISIX, for example:
   
   ```json
   {
       "uri": "/*",
       "vars": [
           ["uri", "~~", ".(js|css|flash|media|jpg|png|gif|ico|vbs|json|txt)$"]
       ]
   }
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [apisix] moonming closed issue #4672: question: Proxy static files with APISIX, how to configure routes

Posted by GitBox <gi...@apache.org>.
moonming closed issue #4672:
URL: https://github.com/apache/apisix/issues/4672


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [apisix] xiangyu123 commented on issue #4672: question: Proxy static files with APISIX, how to configure routes

Posted by GitBox <gi...@apache.org>.
xiangyu123 commented on issue #4672:
URL: https://github.com/apache/apisix/issues/4672#issuecomment-1010682814


   and how to set the nginx root directive, to offer the static files from local directory ?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org