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.

bind apache to a specific port.
#4
RE: bind apache to a specific port.
(12-02-2014, 09:29 AM)TheVP Wrote: Admin > Sentora Config > ctrl+f > Sentora Apache Port

Also,
Admin > Module Admin > Apache Config > ctrl+f > Apache Port

You have to set the both.
I have Varnish running in front of Apache so that's what I did and it works nicely.

config settings:
Senotoa Apache Port: 80
Module Apache Port: 80
result:
# Configuration for Sentora control panel.
Listen 80
<VirtualHost *:80>
# DOMAIN: test.domain
<virtualhost *:80>

config settings:
Senotoa Apache Port: yy.yy.yy.yy:80
Module Apache Port: xx.xx.xx.xx:80
result:
Listen yy.yy.yy.yy:80
Listen xx.xx.xx.xx:80
# Configuration for Sentora control panel.
<VirtualHost *:yy.yy.yy.yy:80>
# DOMAIN: test.domain
<virtualhost *:xx.xx.xx.xx:80>

As you can see from the second example this does not result in proper virtualhost entires. I used xx.xx.xx.xx and yy.yy.yy.yy in this example just to show what config field results in which output entry. The Problem ist just the leading "*:" in the virtualhost lines.

This means it is possible to change the port the apache server is running on, but not to limit the ip-address to a single ip address. The only solution would be to change the line in the code that creates the virtualhost entry.

Code:
       $vhostPort = ( fs_director::CheckForEmptyValue( $rowvhost[ 'vh_custom_port_in' ] ) )
                    ? $VHostDefaultPort
                    : $rowvhost[ 'vh_custom_port_in' ];

       $vhostIp = ( fs_director::CheckForEmptyValue( $rowvhost[ 'vh_custom_ip_vc' ] ) )
                  ? "*"
                  : $rowvhost[ 'vh_custom_ip_vc' ];

Something like adding a VHostDefaultIP would maybe help here. I could do that changes to the code, but thats inside the core of the application and i am sure future updates would break that again. Any suggestions how to go on?

J
Reply
Thanks given by:


Messages In This Thread
bind apache to a specific port. - by j.waibel - 12-02-2014, 06:27 AM
RE: bind apache to a specific port. - by Me.B - 12-02-2014, 07:23 AM
RE: bind apache to a specific port. - by TheVP - 12-02-2014, 09:29 AM
RE: bind apache to a specific port. - by j.waibel - 12-02-2014, 05:57 PM
RE: bind apache to a specific port. - by NIicK - 03-10-2015, 07:11 AM
RE: bind apache to a specific port. - by xanaul - 03-19-2015, 07:36 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
Sentora & Apache behind Nginx Reverse Proxy Feilding Weather 7 13 ,874 08-06-2021, 02:58 PM
Last Post: ccr1969
Postfix relay specific domains to mailjet johnnyp 0 2 ,079 01-29-2021, 04:44 AM
Last Post: johnnyp
How to run multiple version PHP with Apache (use Sentora panel) on Centos ??? BigBang 4 7 ,829 12-23-2020, 03:31 PM
Last Post: djkashdui1

Forum Jump:


Users browsing this thread: 1 Guest(s)