Cpanel is one most flexible platforms and installing Miva Empresa takes a litte structure. To save webmaster a bunch of searching and to config miva to run without trying to modify the httpd.conf is really easy once you grasp the individual includes.
DO NOT MODIFY THE HTTPD.CONF USE THIS INFORMATION, THE CORRECT WAY and your changes don't get WRITTEN OVER
VirtualHost X0.X0.X0.X0:80> y
ServerName domain.com
ServerAlias www.domain.com
DocumentRoot /home/username/public_html
ServerAdmin [email protected]
UseCanonicalName Off
CustomLog /usr/local/apache/domlogs/domain.com combined
CustomLog /usr/local/apache/domlogs/domain.com-bytes_log "%{%s}t %I .\n%{%s}t %O ."
## User username # Needed for Cpanel::ApacheConf
<IfModule !mod_disable_suexec.c>
SuexecUserGroup username username
</IfModule>
ScriptAlias /cgi-bin/ /home/username/public_html/cgi-bin/
Include "/usr/local/apache/conf/userdata/*.conf"
Include "/usr/local/apache/conf/userdata/*.owner-username"
Include "/usr/local/apache/conf/userdata/std/*.conf"
Include "/usr/local/apache/conf/userdata/std/*.owner-username"
Include "/usr/local/apache/conf/userdata/std/2/*.conf"
Include "/usr/local/apache/conf/userdata/std/2/*.owner-username"
Include "/usr/local/apache/conf/userdata/std/2/username/domain.com/*.conf"
Include "/usr/local/apache/conf/userdata/std/2/username/*.conf"
</VirtualHost>
These includes came from making a directory in /usr/local/apache/conf called usersdata, and the sub directories note above. Then run the distiller and the rebulid script and your are on your way, dont forget to restart apache.
mivavm needs to be 4775 (set user id on execution) so that the MivaData and MivaRoot will be able to be seen by miva (ie: no more directory does not exist
errors)'
suExec should be Off in order for the Internal Server Errors to stop; due to the fact that a Server-Wide mode w/ Cpanel will most likely need to be ran as
root and SuExec prevents scripts running as root.
SEE: http://www.cpanel.net/support/docs/ea/ea3/customdirectives.html
[ssl = 1] | [std = 2]
-------------------------------------------------------------------------
Assuming you make a miva-bin directory in the /usr/local/apache/ dir in the same location as the cgi-bin then this make sense:
Global Configuration
Add to Cpanel Pre-main:
AddType application/x-miva-compiled .mvc
Action application/x-miva-compiled /miva-bin/mivavm
ScriptAlias /miva-bin/ "/usr/local/apache/miva-bin/"
Add to Cpanel Pre-VirtualHosts:
SetEnv MvCONFIG_DIR_BUILTIN /usr/local/apache/miva-bin/lib/builtins
SetEnv MvCONFIG_DIR_CA /usr/local/apache/miva-bin/certs
SetEnv MvCONFIG_SSL_OPENSSL /usr/lib/libssl.so
SetEnv MvCONFIG_SSL_CRYPTO /usr/lib/libcrypto.so
SetEnv MvCONFIG_DATABASE_mysql /usr/local/apache/miva-bin/lib/databases/mysql.so
SetEnv MvCONFIG_COMMERCE_authnet /usr/local/apache/miva-bin/lib/commerce/authnet.so
SetEnv MvCONFIG_DIR_MIVA /usr/local/apache/htdocs/
SetEnv MvCONFIG_DIR_DATA /usr/local/apache/mivadata
That is it, if you followed the mive install documentation
http://docs.smallbusiness.miva.com/en-US/merchant/WebHost/webhelp/web_host_resources.htm
Good luck ! This is my contribution as I didn't think that it should be a secret and as server admins we should have complete information. Cpanel support gets a special thanks and kudo too.
Best Regards,
Peter
DO NOT MODIFY THE HTTPD.CONF USE THIS INFORMATION, THE CORRECT WAY and your changes don't get WRITTEN OVER
VirtualHost X0.X0.X0.X0:80> y
ServerName domain.com
ServerAlias www.domain.com
DocumentRoot /home/username/public_html
ServerAdmin [email protected]
UseCanonicalName Off
CustomLog /usr/local/apache/domlogs/domain.com combined
CustomLog /usr/local/apache/domlogs/domain.com-bytes_log "%{%s}t %I .\n%{%s}t %O ."
## User username # Needed for Cpanel::ApacheConf
<IfModule !mod_disable_suexec.c>
SuexecUserGroup username username
</IfModule>
ScriptAlias /cgi-bin/ /home/username/public_html/cgi-bin/
Include "/usr/local/apache/conf/userdata/*.conf"
Include "/usr/local/apache/conf/userdata/*.owner-username"
Include "/usr/local/apache/conf/userdata/std/*.conf"
Include "/usr/local/apache/conf/userdata/std/*.owner-username"
Include "/usr/local/apache/conf/userdata/std/2/*.conf"
Include "/usr/local/apache/conf/userdata/std/2/*.owner-username"
Include "/usr/local/apache/conf/userdata/std/2/username/domain.com/*.conf"
Include "/usr/local/apache/conf/userdata/std/2/username/*.conf"
</VirtualHost>
These includes came from making a directory in /usr/local/apache/conf called usersdata, and the sub directories note above. Then run the distiller and the rebulid script and your are on your way, dont forget to restart apache.
mivavm needs to be 4775 (set user id on execution) so that the MivaData and MivaRoot will be able to be seen by miva (ie: no more directory does not exist
errors)'
suExec should be Off in order for the Internal Server Errors to stop; due to the fact that a Server-Wide mode w/ Cpanel will most likely need to be ran as
root and SuExec prevents scripts running as root.
SEE: http://www.cpanel.net/support/docs/ea/ea3/customdirectives.html
[ssl = 1] | [std = 2]
-------------------------------------------------------------------------
Assuming you make a miva-bin directory in the /usr/local/apache/ dir in the same location as the cgi-bin then this make sense:
Global Configuration
Add to Cpanel Pre-main:
AddType application/x-miva-compiled .mvc
Action application/x-miva-compiled /miva-bin/mivavm
ScriptAlias /miva-bin/ "/usr/local/apache/miva-bin/"
Add to Cpanel Pre-VirtualHosts:
SetEnv MvCONFIG_DIR_BUILTIN /usr/local/apache/miva-bin/lib/builtins
SetEnv MvCONFIG_DIR_CA /usr/local/apache/miva-bin/certs
SetEnv MvCONFIG_SSL_OPENSSL /usr/lib/libssl.so
SetEnv MvCONFIG_SSL_CRYPTO /usr/lib/libcrypto.so
SetEnv MvCONFIG_DATABASE_mysql /usr/local/apache/miva-bin/lib/databases/mysql.so
SetEnv MvCONFIG_COMMERCE_authnet /usr/local/apache/miva-bin/lib/commerce/authnet.so
SetEnv MvCONFIG_DIR_MIVA /usr/local/apache/htdocs/
SetEnv MvCONFIG_DIR_DATA /usr/local/apache/mivadata
That is it, if you followed the mive install documentation
http://docs.smallbusiness.miva.com/en-US/merchant/WebHost/webhelp/web_host_resources.htm
Good luck ! This is my contribution as I didn't think that it should be a secret and as server admins we should have complete information. Cpanel support gets a special thanks and kudo too.
Best Regards,
Peter
Last edited: