Skip to content
Snippets Groups Projects
Commit 871b338c authored by tbrehm's avatar tbrehm
Browse files

- Updated ubuntu installation instructions.

- Fixed a few bugs in suphp implementation.
parent 326a8dbb
No related branches found
No related tags found
No related merge requests found
...@@ -17,10 +17,11 @@ apt-get -u upgrade ...@@ -17,10 +17,11 @@ apt-get -u upgrade
1) Install Postfix, Courier, Saslauthd, MySQL, phpMyAdmin with the following command line (on one line!): 1) Install Postfix, Courier, Saslauthd, MySQL, phpMyAdmin with the following command line (on one line!):
apt-get install postfix postfix-mysql postfix-doc mysql-client mysql-server courier-authdaemon courier-authlib-mysql courier-pop courier-pop-ssl courier-imap courier-imap-ssl postfix-tls libsasl2-2 libsasl2-modules libsasl2-modules-sql sasl2-bin libpam-mysql openssl courier-maildrop getmail4 apt-get install postfix postfix-mysql postfix-doc mysql-client mysql-server courier-authdaemon courier-authlib-mysql courier-pop courier-pop-ssl courier-imap courier-imap-ssl libsasl2-2 libsasl2-modules libsasl2-modules-sql sasl2-bin libpam-mysql openssl courier-maildrop getmail4
Answer the questions from the package manager as follows. Answer the questions from the package manager as follows.
Enter the mysql root password.
Create directories for web-based administration ? <-- No Create directories for web-based administration ? <-- No
General type of configuration? <-- Internet site General type of configuration? <-- Internet site
Mail name? <-- server1.mydomain.tld Mail name? <-- server1.mydomain.tld
...@@ -43,6 +44,25 @@ a2enmod suexec ...@@ -43,6 +44,25 @@ a2enmod suexec
a2enmod rewrite a2enmod rewrite
a2enmod ssl a2enmod ssl
Optional: Install SuPHP
apt-get install libapache2-mod-suphp
vi /etc/suphp/suphp.conf
set docroot to:
docroot=/var/clients
Change:
application/x-httpd-php=php:/usr/bin/php-cgi
to:
x-httpd-php=php:/usr/bin/php-cgi
4) Install pure-ftpd and quota 4) Install pure-ftpd and quota
First we have to make sure that the capability module is loaded in the kernel First we have to make sure that the capability module is loaded in the kernel
...@@ -61,9 +81,9 @@ echo 'yes' > /etc/pure-ftpd/conf/DontResolve ...@@ -61,9 +81,9 @@ echo 'yes' > /etc/pure-ftpd/conf/DontResolve
apt-get install g++ libc6 gcc gawk make texinfo libmysqlclient15-dev apt-get install g++ libc6 gcc gawk make texinfo libmysqlclient15-dev
cd /tmp cd /tmp
wget http://mydns.bboy.net/download/mydns-1.1.0.tar.gz wget http://heanet.dl.sourceforge.net/sourceforge/mydns-ng/mydns-1.2.8.4.tar.gz
tar xvfz mydns-1.1.0.tar.gz tar xvfz mydns-1.2.8.4.tar.gz
cd mydns-1.1.0 cd mydns-1.2.8
./configure ./configure
make make
make install make install
...@@ -87,7 +107,7 @@ and enter the following lines (between the ----- lines): ...@@ -87,7 +107,7 @@ and enter the following lines (between the ----- lines):
set -e set -e
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
DAEMON=/usr/sbin/mydns DAEMON=/usr/local/sbin/mydns
NAME=mydns NAME=mydns
DESC="DNS server" DESC="DNS server"
......
...@@ -610,6 +610,11 @@ class installer_base { ...@@ -610,6 +610,11 @@ class installer_base {
//* Create the logging directory for the vhost logfiles //* Create the logging directory for the vhost logfiles
exec('mkdir -p /var/log/ispconfig/httpd'); exec('mkdir -p /var/log/ispconfig/httpd');
if(is_file('/etc/suphp/suphp.conf')) {
replaceLine('/etc/suphp/suphp.conf','application/x-httpd-php=php:/usr/bin/php-cgi','x-httpd-suphp=php:/usr/bin/php-cgi',0);
replaceLine('/etc/suphp/suphp.conf','docroot=','docroot=/var/clients',0);
}
} }
public function configure_firewall() public function configure_firewall()
......
...@@ -12,34 +12,28 @@ NameVirtualHost *:{vhost_port} ...@@ -12,34 +12,28 @@ NameVirtualHost *:{vhost_port}
DocumentRoot /usr/local/ispconfig/interface/web/ DocumentRoot /usr/local/ispconfig/interface/web/
<IfModule mod_fastcgi.c> <IfModule mod_fastcgi.c>
<Location /php/php-fcgi> SuexecUserGroup ispconfig ispconfig
Options ExecCGI <Directory /var/www/ispconfig/>
SetHandler fastcgi-script Options Indexes FollowSymLinks MultiViews +ExecCGI
</Location> AllowOverride AuthConfig Indexes Limit Options FileInfo
AddHandler fcgid-script .php
Action php-fastcgi /php/php-fcgi FCGIWrapper /var/www/php-fcgi-scripts/ispconfig/php-fcgi-starter .php
AllowOverride None
ScriptAlias /php/ /usr/local/ispconfig/interface/bin/ Order allow,deny
Allow from all
<Directory "/usr/local/ispconfig/interface/bin/"> </Directory>
AllowOverride None
Options +ExecCGI -MultiViews -Indexes
Order allow,deny
Allow from all
</Directory>
</IfModule> </IfModule>
<IfModule mod_php5.c> <IfModule mod_php5.c>
AddType application/x-httpd-php .php AddType application/x-httpd-php .php
<Directory /usr/local/ispconfig/interface/web>
Options FollowSymLinks
AllowOverride None
Order allow,deny
Allow from all
</Directory>
</IfModule> </IfModule>
<Directory /usr/local/ispconfig/interface/web/>
Options FollowSymLinks
AllowOverride None
Order allow,deny
Allow from all
</Directory>
# ErrorLog /var/log/apache2/error.log # ErrorLog /var/log/apache2/error.log
# CustomLog /var/log/apache2/access.log combined # CustomLog /var/log/apache2/access.log combined
ServerSignature Off ServerSignature Off
......
...@@ -31,5 +31,7 @@ $wb['New Language'] = 'New Language'; ...@@ -31,5 +31,7 @@ $wb['New Language'] = 'New Language';
$wb['Export'] = 'Export'; $wb['Export'] = 'Export';
$wb['Import'] = 'Import'; $wb['Import'] = 'Import';
$wb['Language Editor'] = 'Language Editor'; $wb['Language Editor'] = 'Language Editor';
$wb['Software'] = 'Software';
$wb['Repositories'] = 'Repositories';
?> ?>
\ No newline at end of file
...@@ -85,6 +85,25 @@ $module['nav'][] = array( 'title' => 'Firewall', ...@@ -85,6 +85,25 @@ $module['nav'][] = array( 'title' => 'Firewall',
// cleanup // cleanup
unset($items); unset($items);
$items[] = array( 'title' => 'Repositories',
'target' => 'content',
'link' => 'admin/software_repo_list.php');
$module['nav'][] = array( 'title' => 'Software',
'open' => 1,
'items' => $items);
// cleanup
unset($items);
/*
$items[] = array( 'title' => 'Add user', $items[] = array( 'title' => 'Add user',
'target' => 'content', 'target' => 'content',
'link' => 'admin/dbsync_edit.php'); 'link' => 'admin/dbsync_edit.php');
...@@ -105,6 +124,7 @@ $module['nav'][] = array( 'title' => 'DB Sync.', ...@@ -105,6 +124,7 @@ $module['nav'][] = array( 'title' => 'DB Sync.',
// cleanup // cleanup
unset($items); unset($items);
*/
......
<VirtualHost <tmpl_var name='ip_address'>:80> <VirtualHost <tmpl_var name='ip_address'>:80>
DocumentRoot <tmpl_var name='web_document_root'> <tmpl_if name='php' op='==' value='suphp'>
DocumentRoot <tmpl_var name='web_document_root'>
</tmpl_else>
DocumentRoot <tmpl_var name='web_document_root_www'>
</tmpl_if>
ServerName <tmpl_var name='domain'> ServerName <tmpl_var name='domain'>
ServerAdmin webmaster@<tmpl_var name='domain'> ServerAdmin webmaster@<tmpl_var name='domain'>
ErrorLog <tmpl_var name='document_root'>/log/error.log ErrorLog <tmpl_var name='document_root'>/log/error.log
...@@ -13,7 +18,7 @@ ...@@ -13,7 +18,7 @@
ErrorDocument 500 /error/internalServerError.html ErrorDocument 500 /error/internalServerError.html
ErrorDocument 503 /error/overloaded.html ErrorDocument 503 /error/overloaded.html
<Directory <tmpl_var name='web_document_root'>/> <Directory {tmpl_var name='web_document_root_www'}>
Options None Options None
AllowOverride Indexes AuthConfig Limit FileInfo AllowOverride Indexes AuthConfig Limit FileInfo
Order allow,deny Order allow,deny
...@@ -43,12 +48,12 @@ ...@@ -43,12 +48,12 @@
AddType application/x-httpd-php .php .php3 .php4 .php5 AddType application/x-httpd-php .php .php3 .php4 .php5
</tmpl_if> </tmpl_if>
<tmpl_if name='php' op='==' value='suphp'> <tmpl_if name='php' op='==' value='suphp'>
<Directory <tmpl_var name='web_document_root'>/> <Directory {tmpl_var name='web_document_root'}>
# suphp enabled # suphp enabled
suPHP_Engine on suPHP_Engine on
# suPHP_UserGroup <tmpl_var name='system_user'> <tmpl_var name='system_group'> # suPHP_UserGroup <tmpl_var name='system_user'> <tmpl_var name='system_group'>
AddHandler x-httpd-php .php .php3 .php4 .php5 AddHandler x-httpd-suphp .php .php3 .php4 .php5
suPHP_AddHandler x-httpd-php suPHP_AddHandler x-httpd-suphp
</Directory> </Directory>
</tmpl_if> </tmpl_if>
<tmpl_if name='php' op='==' value='cgi'> <tmpl_if name='php' op='==' value='cgi'>
...@@ -57,7 +62,7 @@ ...@@ -57,7 +62,7 @@
</tmpl_if> </tmpl_if>
<tmpl_if name='php' op='==' value='fast-cgi'> <tmpl_if name='php' op='==' value='fast-cgi'>
# php as fast-cgi enabled # php as fast-cgi enabled
<Directory /var/www/<tmpl_var name='domain'>/web> <Directory {tmpl_var name='web_document_root_www'}>
AddHandler fcgid-script .php .php3 .php4 .php5 AddHandler fcgid-script .php .php3 .php4 .php5
FCGIWrapper <tmpl_var name='fastcgi_starter_path'><tmpl_var name='fastcgi_starter_script'> .php FCGIWrapper <tmpl_var name='fastcgi_starter_path'><tmpl_var name='fastcgi_starter_script'> .php
Options FollowSymLinks +ExecCGI Indexes Options FollowSymLinks +ExecCGI Indexes
......
...@@ -337,6 +337,7 @@ class apache2_plugin { ...@@ -337,6 +337,7 @@ class apache2_plugin {
$vhost_data = $data["new"]; $vhost_data = $data["new"];
$vhost_data["web_document_root"] = $data["new"]["document_root"]."/web"; $vhost_data["web_document_root"] = $data["new"]["document_root"]."/web";
$vhost_data["web_document_root_www"] = "/var/www/".$data["new"]["domain"]."/web";
// Check if a SSL cert exists // Check if a SSL cert exists
$ssl_dir = $data["new"]["document_root"]."/ssl"; $ssl_dir = $data["new"]["document_root"]."/ssl";
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment