Multi php version 5.6 7.0 and 7.2 issue with https

Discussion in 'Installation/Configuration' started by Remy, Jul 6, 2019.

  1. Remy

    Remy New Member

    I use ispconfig 3.1 and i install succefully multiple php version.
    When i acces website with port 80 http it shows the ricgt php version but in https it is always php 5.6.
    I use apache and find no issue in log.
    Do i miss something to make it work with https?
    I'm completly stuck.

    Thank you for your help
    Remy
     
  2. Remy

    Remy New Member

    a2dismod php5
    a2enmod php7.2
    service apache2 restart

    Work in http and https but default php is 7.2 for all not possible to choose.

    Any idea?
    Thank you
    Remy
     
  3. till

    till Super Moderator Staff Member ISPConfig Developer

    There can be only one mod_php version in apache. Install PHP as php-fpm or php-fcgi if you want to choose between multiple versions. mod_php should not be used anymore, ispconfig just supports it for legacy reasons.
     
    Juri Salminen likes this.
  4. Remy

    Remy New Member

    Yes i kwno but when a choose php-fpm in php7.2 version it doesnt use it in https but only in http.
    It was a test to know if by default 7.2 could be used for everything.
     
  5. till

    till Super Moderator Staff Member ISPConfig Developer

    The same PHP handler is always used for http and https in ISPConfig. Just ab guess, you might have used Letsencrypt from the command line instead of using it in ISPConfig which creates a copy of a site that then cannot be changed anymore.

    Please run the command:

    ls /etc/apache2/sites-enabled/* | grep '-le'

    and post the result.
     
  6. Remy

    Remy New Member

    ls /etc/apache2/sites-enabled/* | grep le
    /etc/apache2/sites-enabled/album.lesboisronds.fr.vhost-le-ssl.conf
    /etc/apache2/sites-enabled/album.telandgo.com.vhost-le-ssl.conf
    /etc/apache2/sites-enabled/aquathlonoyonnax.fr.vhost-le-ssl.conf
    /etc/apache2/sites-enabled/associationfelain.fr.vhost-le-ssl.conf
    /etc/apache2/sites-enabled/boutique.associationfelain.fr.vhost-le-ssl.conf
    /etc/apache2/sites-enabled/chalets-gites-jura.com.vhost-le-ssl.conf
    /etc/apache2/sites-enabled/content-avocat.com.vhost-le-ssl.conf
    /etc/apache2/sites-enabled/etd-moules.fr.vhost-le-ssl.conf
    /etc/apache2/sites-enabled/gilbert-avocat.com.vhost-le-ssl.conf
    /etc/apache2/sites-enabled/lesboisronds.fr.vhost-le-ssl.conf
    /etc/apache2/sites-enabled/piwik.telandgo.com.vhost-le-ssl.conf
    /etc/apache2/sites-enabled/schafercoaching.com.vhost-le-ssl.conf
    /etc/apache2/sites-enabled/smokeping.telandgo.com.vhost-le-ssl.conf
    /etc/apache2/sites-enabled/telandgo.com.vhost-le-ssl.conf
    /etc/apache2/sites-enabled/telandgo.fr.vhost-le-ssl.conf
    /etc/apache2/sites-enabled/ticket.telandgo.com.vhost-le-ssl.conf
    /etc/apache2/sites-enabled/travaux.telandgo.com.vhost-le-ssl.conf
    /etc/apache2/sites-enabled/webcam2.lesboisronds.fr.vhost-le-ssl.conf
    /etc/apache2/sites-enabled/webcam.lesboisronds.fr.vhost-le-ssl.conf
     
  7. till

    till Super Moderator Staff Member ISPConfig Developer

    Ok, there you have the problem. You used let's encrypt manually on the shell on all these sites instead of using the Let's encrypt checkbox in the website settings in ISPconfig. The manual use of certbot locked all sites up now so they cannot be managed from within ISPConfig anymore. The only way to fix your issue is to delete all these config files manually and then enable Let's Encrypt in the website settings instead. Ensure that you update ispconfig to git-stable version first by using ispconfig_update.sh command as there is a another bug in certbot where we added a workaround for in ISPConfig git-stable version.

    And to avoid such problems in future, never use certbot on the shell for the websites.
     
  8. Remy

    Remy New Member

    ok understand i will try it thank you for help. I will tell you when i will have try.
     
  9. Remy

    Remy New Member

    i delete file but when i check Let's Encrypt SSL and save and go again into form Let's Encrypt SSL is unchecked.
     
  10. till

    till Super Moderator Staff Member ISPConfig Developer

    Did you update ispconfig first to git-stable as I told you? It will not work if you don't update first.
     
  11. till

    till Super Moderator Staff Member ISPConfig Developer

    And when your server is behind a NAT router, then you'll have to disable the Let's encrypt check under System > server config > web.
     
  12. Remy

    Remy New Member

    server is not behind a nat he is on public ip alone. It seems to work.
    I try on 2 wesite with diferent php versions and https works well on 2 with php version choice.
     
  13. Remy

    Remy New Member

    how about lets encrypt certificate renew? Does a cron job do that alone?
     
  14. till

    till Super Moderator Staff Member ISPConfig Developer

    That's done by ispconfig automatically.
     
  15. Remy

    Remy New Member

    i really like this interface nice job :) thank you for your time :)
     
  16. Remy

    Remy New Member

    i lose my smokeping graph in the way... perhaps i will have to reinstall it.
     
  17. Jesse Norell

    Jesse Norell Well-Known Member

    For what it's worth, I've been running without mod_php even installed on the machine for some time, using php-fpm as the default php interpreter. I've not identified or heard of a single issue with it in ISPConfig, phpmyadmin, or roundcube. (on debian 9)

    As a reference, we have smokeping on one non-ispconfig debian 9 server running php7.0-fpm as the default php interpreter (again, mod_php is not even installed).
     

Share This Page