This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

Having both HTTP & HTTPS (Port 443 and Port 80) sites on a server
#9
RE: Having both HTTP & HTTPS (Port 443 and Port 80) sites on a server
This is the exact same issue as HTTP Service closed (Port 80 Closed)


Me.B I did a push to master branch with this fix. https://github.com/sentora/sentora-core/...76e30f3509

Quote:Fixes issue if not using any sites on port 80
Example: All sites are using SSL, Listen 80 was not being added to the
httpd-vhosts.conf file to allow redirect from 80 to 443.

This is where the issue is in /modules/apache_admin/hooks/OnDeamonRun.hook.php lines 60-63:
PHP Code:
    while ($rowport $portQuery->fetch()) {
        $customPorts[] = (empty($rowport['vh_custom_port_in'])) ? $VHostDefaultPort $rowport['vh_custom_port_in'];
    }
    $customPortList array_unique($customPorts); 

My suggested work around which seems to work for now unless there is  a better way is:
PHP Code:
   while ($rowport $portQuery->fetch()) {
 
       $customPorts[] = (empty($rowport['vh_custom_port_in'])) ? $VHostDefaultPort $rowport['vh_custom_port_in'];
 
   }
 
   // Adds default vhost port to Listen port array
 
   $customPorts[] = $VHostDefaultPort;
 
   $customPortList array_unique($customPorts); 
-TGates - Project Council

SEARCH the Forums or read the DOCUMENTATION before posting!
Support Sentora and Donate: HERE

Find my support or modules useful? Donate to TGates HERE
Developers and code testers needed!
Contact TGates for more information
Reply
Thanks given by:


Messages In This Thread
RE: Having both HTTP & HTTPS (Port 443 and Port 80) sites on a server - by TGates - 08-16-2017, 01:21 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
Server Crash rsthomas 3 6 ,631 05-18-2022, 09:26 AM
Last Post: Nigel
Server Vs. Workstation zHostingSolutions 4 7 ,775 09-14-2021, 06:30 AM
Last Post: sparkrack
https without certificate redirects to panel iraqiboy90 10 19 ,508 02-28-2021, 11:20 AM
Last Post: iraqiboy90

Forum Jump:


Users browsing this thread: 1 Guest(s)