Welcome to Centmin Mod Community
Become a Member

Beta Branch update webp.conf for cloudflare compatibility in 123.09beta01

Discussion in 'Centmin Mod Github Commits' started by eva2000, Apr 2, 2020.

  1. eva2000

    eva2000 Administrator Staff Member

    49,614
    11,390
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +17,696
    Local Time:
    5:37 AM
    Nginx 1.21.x
    MariaDB 10.x
    update webp.conf for cloudflare compatibility in 123.09beta01


    Update Centmin Mod Nginx webP support to allow proper compatibility with Cloudflare Proxy and DNS only modes so when Cloudflare Proxy CDN mode detected disable Centmin Mod Nginx webP due to Cloudflare cache not supporting HTTP Vary header and when Cloudflare DNS only mode detected or in absence of Cloudflare, enable Centmin Mod Nginx webP Wordpress - Playing with EWWW Image Optimizer Wordpress Plugin

    Continue reading...

    123.09beta01 branch
     
  2. eva2000

    eva2000 Administrator Staff Member

    49,614
    11,390
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +17,696
    Local Time:
    5:37 AM
    Nginx 1.21.x
    MariaDB 10.x
    Also updated instructions on official site at https://centminmod.com/webp/ for
    /usr/local/nginx/conf/webp.conf include file's updated contents.
     
  3. BamaStangGuy

    BamaStangGuy Active Member

    665
    191
    43
    May 25, 2014
    Ratings:
    +271
    Local Time:
    1:37 PM
    Have you talked with Cloudflare at all about how their free service is preventing this from working? Curious if they will even do anything as it encourages you to upgrade to their Pro plan.
     
  4. eva2000

    eva2000 Administrator Staff Member

    49,614
    11,390
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +17,696
    Local Time:
    5:37 AM
    Nginx 1.21.x
    MariaDB 10.x
    I haven't but might be something I'd bring up with Cloudflare.
     
  5. eva2000

    eva2000 Administrator Staff Member

    49,614
    11,390
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +17,696
    Local Time:
    5:37 AM
    Nginx 1.21.x
    MariaDB 10.x
  6. adamus007p

    adamus007p Member

    304
    17
    18
    Feb 8, 2019
    Ratings:
    +29
    Local Time:
    8:37 PM
    voted :)
     
  7. pamamolf

    pamamolf Premium Member Premium Member

    3,993
    417
    83
    May 31, 2014
    Ratings:
    +807
    Local Time:
    9:37 PM
    Nginx-1.17.x
    MariaDB 10.3.x
    What if i use the Pro plan?

    Should i remove that code from the webp.conf ?

    How can i get the webp for my images?
     
  8. eva2000

    eva2000 Administrator Staff Member

    49,614
    11,390
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +17,696
    Local Time:
    5:37 AM
    Nginx 1.21.x
    MariaDB 10.x
    If you use Cloudflare paid plans not need to do anything on Centmin Mod Nginx side as updated Nginx webP code above disables Nginx side webP when Cloudflare is detected and all you need to do is enable Cloudflare Polish's webP support and let Cloudflare handle webP and not from Centmin Mod Nginx.
     
  9. pamamolf

    pamamolf Premium Member Premium Member

    3,993
    417
    83
    May 31, 2014
    Ratings:
    +807
    Local Time:
    9:37 PM
    Nginx-1.17.x
    MariaDB 10.3.x
    Yes i have it enabled and set to lossy ..

    I can see the .jpg to be ok as webp but not even one with the extension .jpeg or .png ...
     
  10. eva2000

    eva2000 Administrator Staff Member

    49,614
    11,390
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +17,696
    Local Time:
    5:37 AM
    Nginx 1.21.x
    MariaDB 10.x
    Cloudflare webP via Polish will only convert to webP if size is smaller than original otherwise it uses original file. You can inspect the image url's HTTP headers which will tell you the specifics