Switches (Auto Subdomain, SEO redirect, HTTPS rewrite) valid for ISPConfig with nginx?

Discussion in 'ISPConfig 3 Priority Support' started by itsolon, Mar 7, 2018.

  1. itsolon

    itsolon Member

    Hello,
    now i have successful migrated from plesk to ispconfig with help of support (they made new working version 2.04 for me).
    im struggling now with the switches available in ISPConfig admin:
    the general Question is:
    Switches (Auto Subdomain, SEO redirect, HTTPS rewrite) valid for ISPConfig with nginx?
    because when i am switching on and off (and waiting for deployment (red number in header)) then the functions are ignored or do not work
    what i need:
    i have migrated for example
    • then i use https (rewrite to https?)
    • and additionally i need to have nginx directive for urls ...
      location / { try_files $uri $uri/ /index.php?$args ; }
    but now all of my sites are in a redirect loop
    but i cannot find any error inside
    Additionally i tried to use the pagespeed checkpoint inside your admin
    and due to the reason that obviously no pagespeed is installed in nginx wether dynamically nor static the whole nginx server cannot start anymore because of some website nginx configuration file entries..
    solution: i removed manually and then nginx including ispconfig restarted again.
     
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    Yes, these functions are valid for nginx as well. I use them on all my nginx servers without issues. check if there is a vhost file with .err file ending in the sites-available folder which indicates that nginx did not start with that config, so the last working config was rolled back.
     
  3. itsolon

    itsolon Member

    hmm what distribution do you use? i use debian 9 with nginx but still have problems. no .err file is made the switches do NOT work as expected. im not sure perhaps i should try ubuntu 16.04?
     
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    I use Deboan 8 and 9, Ubuntu 16.04 and CentOS 7 and it works flawlessly on all of them. So changing the distribution will make no difference, the code is always the same and works on all of them.
     
  5. till

    till Super Moderator Staff Member ISPConfig Developer

    Just as a test, I unpacked the vm of the ISPConfig perfect server guide for Debian 9 with nginx, (these guides are the system requirements for any ISPConfig server), created a website, enable http to https redirect and as soon as I access the website with http, I get redirected to https as expected. same with seo redirect and url rewrite.

    A loop happens e.g. when your website (not nginx or the nginx config written by ISPConfig) redirects back to http. This happens when you missed switching the URL inside your cms to https first as the cms tries to enforce http otherwise while nginx tries to enforce https and this results in a loop.
     
  6. itsolon

    itsolon Member

    Thank you for your time.
    OK. as far as i can say, i use wordpress.
    the one which is up at the moment is
    https://www.domain.com
    inside the cms database wordpress is https://www.domain.com for home and siteurl
    i have set:
    domain.tld > www.domain.tld
    http > https
    auto subdomain www
    nginx directive
    location / {
    try_files $uri $uri/ /index.php?$args ;
    }
    with letsencrypt ssl & ssl
    Thats up and running at the moment.

    but after running in the pagespeed checkbox trap and freeing myself
    im reading for
    1. is it worth to build new nginx with pagespeed module on demand
    2. is it worth to update nginx to latest version .. on my debian 9 i have 1.10.3
    3. i have testet http2 https://tools.keycdn.com/http2-test but it seems that in standard there is no support for this. is there any easy way to have that supported?
    Best regards Markus
     
  7. till

    till Super Moderator Staff Member ISPConfig Developer

    You can use the Debian stretch backports to update nginx to a newer version. By installing the nginx-extras package, you get HTTP/2 support as well:

    https://packages.debian.org/stretch-backports/nginx-extras

    you might have to adjust the standard vhost template for HTTP/2 support then, but that should be failry easy as ISPConfig supports custom templates out of the box.

    Page speed module is not included there but I have it installed on my Debian 8 systems but don't use it anymore and did not install it on new Debian 9 systems.
     
  8. itsolon

    itsolon Member

    i managed to install latest stable nginx 1.12.2 now on my server but forgot to copy the previous nginx configuration from ispconfig.
    in this nginx version --with-http_v2_module is already included.
    of course ispconfig does not start anymore.
    do you have a suggestion how can i get ispconfig to reconfigure? or how to manage that?
    Best regards Markus
     
  9. till

    till Super Moderator Staff Member ISPConfig Developer

    From where did you install that version? e.g. the packages from nginx.org run under a wrong user and group and are different from the ones that ship with Debian, so they don't work well.

    You can let ISPConfig reconfigure services by doing an ISPConfig update and choosing yes when the updater asks to reconfigure services. If your ISPConfig version is already the latest version, then do the manual update as decsribed in the release notes. https://www.ispconfig.org/blog/ispconfig-3-1-11-released-seurity-bugfix-update/
     
  10. itsolon

    itsolon Member

    You are right i got the package directly from nginx.org .. ok now i was able to revert to nginx 1.10.3 from standard.
    now i figured out that in standard nginx debian 9 http2 is already included.
    i just have to call http2 with a directive somehow..
    dont know how to manage this, compression is also missing
     

Share This Page