Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nginx not serving updated files #595

Closed
alystair opened this issue Jun 7, 2018 · 2 comments
Closed

Nginx not serving updated files #595

alystair opened this issue Jun 7, 2018 · 2 comments

Comments

@alystair
Copy link

alystair commented Jun 7, 2018

Was directed here by @cretueusebiu - maintainer of the Windows port of Valet. Copy of the issue I submitted to his repo @ cretueusebiu#88

Sometimes Nginx does not recognize files have been modified, as such browsers reload from disk cache - since Valet is a development environment wouldn't it make sense to specifically disable caching mechanisms?

Nginx is specifically returning cache tags in response headers

Date: Sat, 02 Jun 2018 19:29:15 GMT
ETag: W/"5b1126c5-4a3"
Last-Modified: Fri, 01 Jun 2018 10:58:13 GMT
@drbyte
Copy link
Contributor

drbyte commented Sep 24, 2018

You didn't state what "kinds" of resources were particularly troublesome in this context.

I haven't run into any situation where this was an issue that seemed to be needing fixing.
ie: when dealing with resources that are likely to be cached by the browser it's been normal "muscle memory" to ask the browser for a refresh.

The default nginx configs in valet are pretty generic, and don't touch any defaults related to caching (save for enabling gzip, which can influence the strength of ETag value matching).

So, if you wish to customize it, note a simple trick with Valet:
All the ~/.config/valet/Nginx/*.* files get loaded inside the nginx http config section, which means you could drop a cache-dev.conf file in there with any directives you want for disabling caching.

@drbyte
Copy link
Contributor

drbyte commented Jan 16, 2019

I believe this can be closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants