-
Notifications
You must be signed in to change notification settings - Fork 12
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
Add support for page cache #15
Conversation
96e316c
to
d0831c9
Compare
d0831c9
to
0aee311
Compare
php/docker/templates/nginx-vhost-conf.d/75-page-cache-locations.conf
Outdated
Show resolved
Hide resolved
bd19bf6
to
429c0ec
Compare
} | ||
|
||
# Don't cache uris containing the following segments | ||
if ($request_uri ~* "/wp-admin/|/xmlrpc.php|wp-.*.php|/feed/|index.php|sitemap(_index)?.xml") { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It should work for multisites, right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It needs to be tested in that scenario to know for sure.
e570753
to
e69c116
Compare
cd67461
to
6a3ab4f
Compare
6a3ab4f
to
fcf2d49
Compare
php/docker/templates/nginx-vhost-conf.d/page-cache.d/10-index.conf
Outdated
Show resolved
Hide resolved
fcf2d49
to
e7ab358
Compare
php/docker/templates/nginx-vhost-conf.d/75-page-cache-locations.conf
Outdated
Show resolved
Hide resolved
|
||
redis2_query set $key $echo_request_body; | ||
redis2_query expire $key $exptime; | ||
redis2_pass {{ default "localhost:6379" .Env.STACK_PAGE_CACHE_REDIS_HOST_PATH }}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
redis2_pass {{ default "localhost:6379" .Env.STACK_PAGE_CACHE_REDIS_HOST_PATH }}; | |
redis2_pass {{ default "localhost" .Env.STACK_PAGE_CACHE_REDIS_HOST }}:{{ default "6379" .Env.STACK_PAGE_CACHE_REDIS_PORT }}; |
And add Redis password:
{{ with .Env.STACK_PAGE_CACHE_REDIS_PASSWORD }}
redis2_query auth {{ . }}
{{- end }}
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can work on this in a later PR, since it's not so straightforward. See:
openresty/srcache-nginx-module#60
openresty/srcache-nginx-module#41
php/docker/templates/nginx-vhost-conf.d/page-cache.d/10-index.conf
Outdated
Show resolved
Hide resolved
e7ab358
to
4fd6851
Compare
No description provided.