I'm using nginx to serve static files. I have several js files and different client require different combination of the available files. Is it possible that nginx will combine the files in the request in the first time and then on subsequent requests will serve the cached combined version? Every time I'll upload a new version I'll just clear the cache folder.
Do I need to use a separate script to do it? Is it possible to use python? I rather have simplicity then speed because creating a new combination won't happen to frequently.
Client will request something like http://www.example.com/static?file1%5Ffile2%5Ffile2.js