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.
#31
RE: Using Custom Vhost Entries for Webmail, MySQL, Etc.
Hello, I've installed zpanel 10.1.1 and we put in httpd-vhost this:

(02-03-2015, 11:13 PM)Diablo925 Wrote: On Linux

Remember to add </VirtualHost> at the start

and no </VirtualHost> at the end Smile

Webmail:
Code:
</VirtualHost>

# Configuration for WebMail
<VirtualHost *:80>
 ServerAlias webmail.*
 DocumentRoot "/etc/sentora/panel/etc/apps/webmail/"
 AddType application/x-httpd-php .php
 <Directory "/etc/sentora/panel/etc/apps/webmail/">
 Options +FollowSymLinks -Indexes
 AllowOverride All
 Require all granted
 </Directory> 
Phpmyadmin / Mysql
Code:
</VirtualHost>

# Configuration for PHPmyadmin   
<VirtualHost *:80>
 ServerAlias pma.*
 DocumentRoot "/etc/sentora/panel/etc/apps/phpmyadmin/"
 AddType application/x-httpd-php .php
 <Directory "/etc/sentora/panel/etc/apps/phpmyadmin/">
 Options +FollowSymLinks -Indexes
 AllowOverride All
 Require all granted
 </Directory>

And I've any problem but when past the time, zpanel resets this file and removes this configuration. Do anyone know could I stop it?

Thanks
Emilio
Reply
Thanks given by:
#32
RE: Using Custom Vhost Entries for Webmail, MySQL, Etc.
It tells you how in the first post...
-TGates - Head of Support

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

Find my support helpful? Donate HERE
Help me to help you by getting your domains using this link:
GoDaddy - Domains
Reply
Thanks given by:
#33
RE: Using Custom Vhost Entries for Webmail, MySQL, Etc.
i have default page (Your hosting space is ready...) when i try this ...
Reply
Thanks given by:
#34
RE: Using Custom Vhost Entries for Webmail, MySQL, Etc.
here tooSad


(08-27-2015, 05:51 AM)imrane555 Wrote: i have default page (Your hosting space is ready...) when i try this ...
Reply
Thanks given by:
#35
RE: Using Custom Vhost Entries for Webmail, MySQL, Etc.
(08-27-2015, 10:20 PM)henrique araujo Wrote: here tooSad


(08-27-2015, 05:51 AM)imrane555 Wrote: i have default page (Your hosting space is ready...) when i try this ...

it is because centos i think
Reply
Thanks given by:
#36
RE: Using Custom Vhost Entries for Webmail, MySQL, Etc.
i use ubuntu :/

(08-28-2015, 12:03 AM)imrane555 Wrote:
(08-27-2015, 10:20 PM)henrique araujo Wrote: here tooSad


(08-27-2015, 05:51 AM)imrane555 Wrote: i have default page (Your hosting space is ready...) when i try this ...

it is because centos i think
Reply
Thanks given by:
#37
RE: Using Custom Vhost Entries for Webmail, MySQL, Etc.
I think it has to do with this section:

Code:
       <Directory />
       Options FollowSymLinks Indexes
       AllowOverride All
       Order Allow,Deny
       Allow from all
       </Directory>
As it is different depending on OS, and PHP version.
-TGates - Head of Support

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

Find my support helpful? Donate HERE
Help me to help you by getting your domains using this link:
GoDaddy - Domains
Reply
Thanks given by:
#38
RE: Using Custom Vhost Entries for Webmail, MySQL, Etc.
i use this versio of php:
PHP Version 5.6.12-1+deb.sury.org~trusty+1
Reply
Thanks given by:
#39
RE: Using Custom Vhost Entries for Webmail, MySQL, Etc.
I have done this on CentOS 7 and Sentora 1.0.3 for Webmail as a subdomain and it appears to work with no problems.

Create the subdomain as usual using the Subdomain UI.  After Sentora creates the subdomain , open a terminal and type the following changing any of the capitalized code to fit your configuration:

Code:
cp /var/sentora/USERNAME/hostdata/public_html/webmail_DOMAIN_TLD/* /var/sentora/USERNAME/hostdata/public_html/webmail_DOMAIN_TLD.backup

ln -s /etc/sentora/panel/etc/apps/webmail /var/sentora/USERNAME/hostdata/public_html/webmail_DOMAIN_TLD

I hope that I have the cp command right.  I use so many different systems that I tend use desktops to do this so I don't have to remember all the intricacies of each OS.  If not, please feel free to correct me and I'll make the appropriate edit.

Goto Module Admin, Apache Config.  Under Override a Virtual Host Setting select the subdomain that you just created.  In the Custom Entry box enter the following code again changing any of the capitalized code to fit your configuration:

Code:
php_admin_value open_basedir "/var/sentora/hostdata/USERNAME/hostdata/public_html/webmail_DOMAIN_TLD:/var/sentora/temp/:/etc/sentora/configs/roundcube/:/var/sentora/logs/roundcube/"

Click Save Vhost and wait for the changes to be applied.
Reply
Thanks given by:
#40
RE: Using Custom Vhost Entries for Webmail, MySQL, Etc.
(02-16-2015, 04:03 AM)TGates Wrote:
Code:
ServerAlias webmail.*
Possibly this line. I have tried it in the past also with no luck, I settled on using:
Code:
Alias /webmail /etc/sentora/panel/etc/apps/webmail
as a Global Vhost Entry in Module Admin > Apache Config.
This allows all domains and subdomains to use domain.com/webmail to access roundcube and has worked without flaw for a few years now.
(I also use a similar variation for external phpmyadmin login.)
Doing it this way also prevents clients from having to add a webmail record to their DNS settings. Much easier for everybody Wink

You need to lose Required all Granted line.
Works fine then for me.
[Image: logo2.png]

My being on this forum is all personal and all is done here by me has nothing to with the company Web Improved I work for Smile
Reply
Thanks given by: TGates


Possibly Related Threads...
Thread Author Replies Views Last Post
SSL and Custom Vhost Entries for Webmail etienne7702 4 382 03-19-2017, 09:16 AM
Last Post: TGates
Custom Error Pages/Static Pages TGates 8 6,070 05-11-2016, 03:15 PM
Last Post: Kumar
How to overwrite default admin. vhost? NIicK 1 693 03-27-2016, 01:16 AM
Last Post: Me.B

Forum Jump:


Users browsing this thread: 1 Guest(s)