Get the most out of your Centmin Mod LEMP stack
Become a Member

Beta Branch update nginx 1.27.4 default with optional SSL cert cache support in 140.00beta01

Discussion in 'Centmin Mod Github Commits' started by eva2000, Feb 6, 2025.

Tags:
  1. eva2000

    eva2000 Administrator Staff Member

    59,329
    12,510
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +19,143
    Local Time:
    3:32 AM
    Nginx 1.31.x
    MariaDB 10.x/11.4+/12.3+
    update nginx 1.27.4 default with optional SSL cert cache support in 140.00beta01

    - update nginx 1.27.4 default with optional SSL certificate and key cache support as outlined at Optimizing Resource Usage for Complex SSL Configurations in NGINX – NGINX Community Blog.
    - existing Centmin Mod 140.00beta01 users can run cmupdate to get update then set in persistent config file /etc/centminmod/custom_config.inc the below variables (latter 2 are optional)
    and then run centmin.sh menu option 4 to recompile/update to Nginx 1.27.4 to enable optional SSL certificate caching for Nginx 1.27.4+
    - NGINX_SSL_CACHE='y' Set to 'y' to activate caching of SSL certs/keys.
    - NGINX_SSL_CACHE_COUNT='1000' which defines the maximum number of cache entries (default: 1000).
    - NGINX_SSL_CACHE_TTLS='1m' which specifies the cache entry valid time in minutes (default: 1m).

    Continue reading...


    140.00beta01 branch
     
  2. rdan

    rdan Well-Known Member

    5,452
    1,418
    113
    May 25, 2014
    Ratings:
    +2,212
    Local Time:
    1:32 AM
    Mainline
    10.2
    So the new configuration that is mostly relevant to us is:
    ssl_certificate_cache max=N [inactive=time] [valid=time];
     
  3. pamamolf

    pamamolf Well-Known Member

    4,126
    429
    83
    May 31, 2014
    Ratings:
    +841
    Local Time:
    8:32 PM
    Nginx-1.29.x
    MariaDB 10.6.x
    Can we have a sample of what to use and where exactly in the config?
     
  4. eva2000

    eva2000 Administrator Staff Member

    59,329
    12,510
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +19,143
    Local Time:
    3:32 AM
    Nginx 1.31.x
    MariaDB 10.x/11.4+/12.3+
    Yup :)
    in /usr/local/nginx/conf/nginx.conf, you'd see when enabled an include file /usr/local/nginx/conf/nginx_ssl_cert_cache.conf
    Code (Text):
    http {
     include /usr/local/nginx/conf/nginx_ssl_cert_cache.conf;
    

    and when disabled, commented out include file for /usr/local/nginx/conf/nginx_ssl_cert_cache.conf
    Code (Text):
    http {
     #include /usr/local/nginx/conf/nginx_ssl_cert_cache.conf;
    

    contents of include file /usr/local/nginx/conf/nginx_ssl_cert_cache.conf is
    Code (Text):
    ssl_certificate_cache max=1000 inactive=20s valid=1m;
    

    found a found in my implementation, so 140.00beta01 2nd update coming heh. Edit updated 140.00beta01 with fix :)