Add the varnish
service under the services
section in .docksal/docksal.yml
:
# Varnish
varnish:
extends:
file: ${HOME}/.docksal/stacks/services.yml
service: varnish
depends_on:
- web
Apply new configuration with fin project start
(fin p start
).
Use http://varnish.<VIRTUAL_HOST>
to access the site via Varnish.
Custom VCL is automatically loaded from .docksal/etc/varnish/default.vcl
if one exists in the project codebase.
After making changes to the custom VCL file, reset Varnish with fin project reset varnish
(fin p reset varnish
).
See docksal/service-varnish for additional configuration options and default VCL configs.
Was this page helpful?
Thanks for the feedback. If you have a specific, answerable question about how to use Docksal, ask it in Discussions on GitHub. Open an issue if you want to report a problem or suggest an improvement. You can also contribute changes to this page using the link in the top right corner.