Webp Support in Easyengine V4 #1650
Replies: 1 comment
-
I have the same problem with smush pro plugin, i don't know why that directives are not allowed in user.conf file, althought i am adding the code in .../sitename/config/nginx/custom/user.conf (that's the right place for custom configs). The only way I got smush to recognize that I added the rules to nginx was by adding the rules to the server block of the main.conf file (.../sitename/config/nginx/conf.d/main.conf) I added it right after they declared the favicon location after that i restarted the site and smush recognized that the rules had been added, Below, I show you part of the files: /opt/easyengine/sites/SITENAME/config/nginx/conf.d/main.conf ` Add your custom config in custom/user.confALL CHANGES IN THIS FILE WILL BE LOST AFTER EasyEngine Updateupstream php { upstream redis { server {
#OTHERS CONFIGS
#OTHERS CONFIGS /opt/easyengine/sites/SITENAME/config/nginx/nginx.conf ` events { http {
#OTHERS CONFIGS
#OTHERS CONFIGS After this the webp images works. Anyway, i think this configs must be in user.conf, cause when you upgrade EE this configs will be deleted and you need to do it again and again. I hope this help you. NOTE: search for SITENAME in the text cause it must be the name of your sitename, althought i think that the only place where you need to write it manually is in the rules for nginx.conf PS: I wrote "i have" at beggining cause I just made it work while writing my progress on the spot lol xD |
Beta Was this translation helpful? Give feedback.
-
I want to serve Webp images to my visitors.
I have installed WebP Converter for Media plugin to convert all my media library to Webp.
As for the Configuration part, I need to add the following code to the Nginx config file.
I added the code inside a Webp.conf file which I placed inside the
sitecom_config_nginx/_data/custom/
When trying to restart Nginx I got map directive is not allowed here error.
How can I make this work?
I'm on the latest version of EE which is v4.5.3
Beta Was this translation helpful? Give feedback.
All reactions