Viewing 8 replies - 1 through 8 (of 8 total)
  • Plugin Author Max GJ Panas

    (@max-gjp)

    Hey Ricky,

    I have not tried WPEngine, why do you suggest it in particular?

    Yeah, I am not an expert on nginx and so was hoping someone who was would translate Media Vault’s rewrite rules over to an nginx setup. In the Media Vault Activation Helper, that will appear if someone tries to enable Media Vault on an nginx setup, the Apache .htaccess rules are provided in case the user wants to try and convert them.

    I’ll try and spin up an nginx server on my pc and set it up for testing.

    WPEngine has gained a lot of traction in community – sponsoring WordCamps, speaking at events, etc.

    Many of the VIP Partners use them when not developing on WordPress.com VIP.

    WPEngine is also in part financially backed by Automattic.

    Plugin Author Max GJ Panas

    (@max-gjp)

    Hey Ricky Lee 2!

    How would they particularly help with the issue at hand however?

    Thanks.

    They are likely the #1 Nginx WordPress managed host. I would spin up a configuration there for testing.

    Plugin Author Max GJ Panas

    (@max-gjp)

    Ok thanks ricky, I’ll consider it.

    I will try and get back in a couple of days with a potential nginx solution. In the mean time if you succeed in setting it up, let me know here.

    Thanks

    *bump*

    Any progress on this front? I tried to convert the .htaccess rules for Media Vault into the syntax for nginx configuration instructions using this tool https://winginx.com/en/htaccess.

    # nginx configuration
    location /wp {
    rewrite ^/wp-content/uploads(/_mediavault/.*\.\w+)$ /index.php?mgjp_mv_file=$1 break;
    }
    location / {
    if ($query_string ~ "^(?:.*&)?mgjp_mv_download=safeforce(?:&.*)?$"){
    rewrite ^/wp-content/uploads(/.*\.\w+)$ /index.php?mgjp_mv_file=$1 break;
    }
    }

    Alas no luck so far.

    The nginx config below works – once MV is completely activated. But I can’t figure out what nginx config is needed to pass the MV test which enables the complete activation. I fooled MV into complete activation by running on Apache – then I switched to nginx.

    If the author would fully describe the tests that are used to fully enable, then I will try to create the nginx config that satisfies them.

    # Media Vault Rewrite Rules
    
    # RewriteRule ^wp-content/uploads(/_mediavault/.*\.\w+)$ index.php?mgjp_mv_file=$1 [QSA,L]
    rewrite ^/wp-content/uploads(/_mediavault/.*\.\w+)$ /index.php?mgjp_mv_file=$1 last;
    
    # RewriteCond %{QUERY_STRING} ^(?:.*&)?mgjp_mv_download=safeforce(?:&.*)?$
    # RewriteRule ^wp-content/uploads(/.*\.\w+)$ index.php?mgjp_mv_file=$1 [QSA,L]
    if ($args ~* "^(?:.*&)?mgjp_mv_download=safeforce(?:&.*)?$")
     {
    	rewrite ^/wp-content/uploads(/.*\.\w+)$ /index.php/?mgjp_mv_file=$1 last;
     }
    # Media Vault Rewrite Rules End

    Would like to piggy-back on @flymike’s comment. In a dev environment, I used similar rules and jumped through some hoops to get things activated for validation, but I can’t jump through all of those same hoops in my production environment. The problem is that I can’t use the UI to enable the plugin because whatever conditions are tested fail in an Nginx-driven ecosystem.

    How can we either bypass the validation or inspect the validation tests to see what we need to change?

    Thanks.

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘NGINX Support’ is closed to new replies.