Connecting wordpress website using argo on ngnix

I have a nginx website with wordpress installed. Can anyone guide me how to connect my website using Argo tunnel to cloudflare. How to do the configuration in nginx

I posted a Argo Tunnel guide for my Centmin Mod LEMP stack users which would cover most of what your need besides some specific stuff unique to my stack’s setup. But I also linked to Cloudflare documents for the info you would need to do too https://blog.centminmod.com/2021/02/09/2250/how-to-setup-cloudflare-argo-tunnel-on-centos-7/ (yes my blog is running Argo tunnel :sunglasses:)

1 Like

Hey thanks but it’s not ubuntu and nginx specific so I cannot get it

The theory would be the same so whitelisting firewall instead use iptables/ufw. Spin up a test hourly billed vps with your Ubuntu operating system and test setup Argo first before trying on live server

Hmmm. I want to know how to connect nginx wordpress website to cloudflare.

In yaml config file should I enter my domain or localhost if localhost how to run nginx wordpress on localhost on AWS ec2.

Do I need to configure orgin certificate from cloudflare

How is your website so fast??

localhost/port as it will reference your nginx server/port

No need. My guide at https://blog.centminmod.com/2021/02/09/2250/how-to-setup-cloudflare-argo-tunnel-on-centos-7/ is for my Centmin Mod LEMP stack which is Nginx based so some of the instructions are relevant though the Nginx config paths/files may differ.

Cloudflare cache certain static content https://support.cloudflare.com/hc/en-us/articles/200172516-Which-file-extensions-does-Cloudflare-cache-for-static-content- but not dynamic/static generated html itself by default (which is what WPT TTFB is testing for). But you can tell Cloudflare to cache dynamic/static generated html content i.e. Wordpress pages to some extent depending on Cloudflare plan you’re on via cache everything page rule but have to be careful to only do this for static html content and not dynamic html content (otherwise you would cache private logged in user content).

Or instead of Business plan and higher’s bypass cache on cookie page rule, you can use Cloudflare APO for Wordpress which does a similar thing https://developers.cloudflare.com/automatic-platform-optimization/

To fully optimise a site for performance and speed, you need to optimize 3 segments.

  1. segment 1 - connection between visitor and CF edge server i.e. CDN cache, WAF, Firewall, Page Rules, Mirage, Polish webP, HTTP/2, HTTP/3, CF Workers (i.e. custom/advanced caching) etc
  2. segment 2 - connection between CF edge server and your origin i.e. Argo, Railgun & Full SSL/ECDSA SSL certificates
  3. segment 3 - your origin server’s performance/optimisations i.e. web server, PHP, MySQL server optimisations and server hardware specs.

Cloudflare can only help for segments 1 & 2 for cached guest/non-logged based visitors. Now for Cloudflare CDN cache miss/bypass and logged in user for web apps like forums/wordpress performance is determined by segment 3.

So dynamic pages’ performance could purely be due to segment 3 factors related to your origin server itself i.e. web server, php and/or mysql database performance which need optimizing and/or better hosting.

I am also a page speed performance addict so optimise my pages for Google Core Web Vitals where possible.

According to HTTP Archive’s Core Web Vital Technology report, users who use my Centmin Mod LEMP site have quite a few site origins in the Centmin Mod tech count compared to other technologies too as out of box defaults in my stack are for performance :slight_smile:

So why my Wordpress blog is fast? Is because I have optimised all 3 segments outlined above including segment 3 which is an optimised Centmin Mod Nginx + PHP-FPM + MariaDB server stack with optimised Wordpress installs - see https://blog.centminmod.com/category/wordpress/. My sites running my Centmin Mod LEMP even without Cloudflare are very fast, Cloudflare just makes then fast geographically everywhere due to CDN caching :slight_smile: I also use Cloudflare Enterprise plan with better peering for some countries like India and Australia and also have Cloudflare Argo smart routing enabled and also have a custom Cloudflare Worker doing finer grain control full HTML page caching similar to CF APO. These relate to segments 1 and 2.

For instance, my Centmin Mod LEMP stack can optionally enable PHP-FPM built with Profile Guided Optimizations (PGO) with PGO training for Wordpress and other PHP specific performance profiles which can give an extra 5-20% performance over regular PHP-FPM without PGO. See benchmarks of PGO vs without PGO comparing Centmin Mod PHP-FPM with/without PGO vs non-Centmin Mod regular Remi YUM repo PHP-FPM on my Centmin Mod community forum.

higher requests/s is faster

lower (ms) time is faster

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.