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.

Using Custom Vhost Entries for Webmail, MySQL, Etc.
#1
Using Custom Vhost Entries for Webmail, MySQL, Etc.
You can use these custom vhost entries to customize sub-domains for various apps:

NOTICE: This could be vulnerable as the sub domains are not locked down using suhosin. Use at your own risk!


Module Admin>Apache Config>Override a Virtual Host Setting>[select domain]>Custom Entry
(Customize file/folder paths to work with your server setup.)
(NOTE: Do NOT add these sub-domains in the sub-domain module!)

Code:
Code:
</VirtualHost>

    # Configuration for phpMyAdmin - mysql.yoursite.tld
    <VirtualHost *:80>
        ServerAdmin webmaster[at]yoursite.tld
        DocumentRoot "/etc/sentora/panel/etc/apps/phpmyadmin/"
        ServerName mysql.yoursite.tld
        AddType application/x-httpd-php .php3 .php
        <Directory />
            php_admin_value open_basedir /etc/sentora/panel/etc/apps/phpmyadmin
            Options FollowSymLinks Indexes
            AllowOverride All
            Order Allow,Deny
            Allow from all
        </Directory>
    </VirtualHost>

    # Configuration for WebMail - webmail.yoursite.tld
    <VirtualHost *:80>
        ServerAdmin webmaster[at]yoursite.tld
        DocumentRoot "/etc/sentora/panel/etc/apps/webmail/"
        ServerName webmail.yoursite.tld
        AddType application/x-httpd-php .php3 .php
        <Directory />
            php_admin_value open_basedir # Alias for roundcube WebMail login
Alias "/webmail" "/etc/sentora/panel/etc/apps/webmail"
<Directory "/etc/sentora/panel/etc/apps/webmail/">
    php_admin_value open_basedir /var/sentora/temp/:/etc/sentora/panel/etc/apps/webmail:/var/sentora/logs/roundcube
    Options +FollowSymLinks -Indexes
    AllowOverride All
    Require all granted
</Directory>
            Options FollowSymLinks Indexes
            AllowOverride All
            Order Allow,Deny
            Allow from all
        </Directory>
You will also need to add them in your DNS registrar and in Sentora's DNS Manager module (add A records for each of mysql.yoursite.tld  and webmail.yoursite.tld, etc.)

NOTE: Changes may take up to 48 hours to work! Be patient
-TGates - Head of Support

SEARCH the Forums or read the DOCUMENTATION before posting!
Modules Maintained: 13 - Module Installs: 108k+

Find my support or modules helpful? Donate HERE
Get your domains using my affiliate link:
GoDaddy - Domains
Reply
Thanks given by: rafaht


Messages In This Thread
Using Custom Vhost Entries for Webmail, MySQL, Etc. - by TGates - 10-22-2014, 05:52 AM

Possibly Related Threads...
Thread Author Replies Views Last Post
SSL and Custom Vhost Entries for Webmail etienne7702 5 9 685 03-08-2018, 09:54 PM
Last Post: etienne7702
Custom Error Pages/Static Pages TGates 8 24 315 05-11-2016, 03:15 PM
Last Post: Kumar
How to overwrite default admin. vhost? NIicK 1 4 430 03-27-2016, 01:16 AM
Last Post: Me.B

Forum Jump:


Users browsing this thread: 1 Guest(s)