Aegir -- CentOS installation instructions Update PHP, install mysql-server, cvs, etc ------------------ # From: http://www.jasonlitka.com/yum-repository/ rpm --import http://www.jasonlitka.com/media/RPM-GPG-KEY-jlitka #Place the following in /etc/sysconfig/rhn/sources : nano -w /etc/yum.repos.d/utterramblings.repo #Place the following in the new file: [utterramblings] name=Jason's Utter Ramblings Repo baseurl=http://www.jasonlitka.com/media/EL$releasever/$basearch/ enabled=1 gpgcheck=1 gpgkey=http://www.jasonlitka.com/media/RPM-GPG-KEY-jlitka # Run (as root): ( yum update yum install postfix cvs mysql-server php-mysql service mysqld start ) # Optional: set the mysql root password -- replace $password with the chosen root password mysqladmin password $password Add the aegir unix account, add some directories ------------------ # Run: ( useradd --home-dir /var/aegir aegir usermod -g apache aegir chmod -R 755 /var/aegir mkdir -p /var/aegir/config/vhost.d mkdir -p /var/aegir/backups chmod 0711 /var/aegir/config chmod 0700 /var/aegir/backups chown -R aegir:apache /var/aegir/* ) # Run: ( su - aegir export DRUPAL_DIR=/var/aegir/drupal-6.14 export AEGIR_TAG=DRUPAL-6--0-4-ALPHA2 cd /var/aegir export CVSROOT=:pserver:anonymous:anonymous@cvs.drupal.org:/cvs/drupal cvs co -d drush -rDRUPAL-6--2-0 contributions/modules/drush export DRUSH=/var/aegir/drush/drush.php cvs co -d .drush/provision -r$AEGIR_TAG contributions/modules/provision $DRUSH dl drupal cd $DRUPAL_DIR cvs co -d profiles/hostmaster -r$AEGIR_TAG contributions/profiles/hostmaster cvs co -d profiles/hostmaster/modules/hosting -r$AEGIR_TAG contributions/modules/hosting $DRUSH dl --destination=./profiles/hostmaster/modules install_profile_api-6.x-2.1 cvs co -d profiles/hostmaster/themes/eldir -r$AEGIR_TAG contributions/themes/eldir $DRUSH dl --destination=./profiles/hostmaster/modules admin_menu ) # Replace aegir.example.com with your chosen Aegir domain ( cd $DRUPAL_DIR export AEGIR_DOMAIN=aegir.resonancedev.net cp profiles/hostmaster/apache2.conf.txt ../config/vhost.d/$AEGIR_DOMAIN ) # Edit the vhost config -- change the domain name for Aegir, and specify the 6.x version (6.14 in our case): vim ../config/vhost.d/$AEGIR_DOMAIN # Include the Aegir config ( logout echo "Include /var/aegir/config/vhost.d/" > /etc/httpd/conf.d/aegir.conf service httpd restart ) Checkpoint! ----------- At this point, you have checked out all the code and setup your basic Drupal (Drupal core, hosting, hostmaster and eldir) that will be the Aegir frontend and the backend system (provision and drush). Your filesystem layout should look something like that:: /var/aegir/drupal-6.x /var/aegir/drupal-6.x/profiles/hostmaster /var/aegir/drupal-6.x/profiles/hostmaster/modules/hosting /var/aegir/drupal-6.x/profiles/hostmaster/modules/install_profile_api /var/aegir/drupal-6.x/profiles/hostmaster/themes/eldir /var/aegir/drupal-6.x/sites/aegir.example.com /var/aegir/config/vhost.d /var/aegir/backups /var/aegir/drush/drush.php /var/aegir/.drush/provision Variations on this are acceptable (for example, the Drush Debian package works out of ``/usr/bin/drush`` and that's fine), but you are better to stick with those if you really want to get through this. The remaining of the documentation here will assume that layout. $ mysql -uroot -p # Enter your root password # Replace 'aegir_password' with the chosen password for 'aegir' mysql account CREATE DATABASE aegir; GRANT SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, INDEX, ALTER, \ CREATE TEMPORARY TABLES, LOCK TABLES ON aegir.* TO \ 'aegir'@'localhost' IDENTIFIED BY 'aegir_password'; # Create a mysql super user (with GRANT OPTION) # Replace 'aegir_root_password' with a new password GRANT ALL PRIVILEGES ON *.* TO 'aegir_root'@'localhost' \ IDENTIFIED BY 'aegir_root_password' WITH GRANT OPTION; Install Drupal ------------------ We are almost ready to install the first Drupal using this installation profile. The installer is going to complain about the missing settings.php. It is recommended that you create the aegir site as a real site in the sites/ directory. The following commands will create this site directory and create the settings.php and files directory with the appropriate permissions to proceed through the installer. Run these commands as the aegir user. $ su - aegir Tell aegir which domain to be served from: $ export AEGIR_DOMAIN=aegir.resonancedev.net # Run: ( cd drupal-6.14/ mkdir sites/$AEGIR_DOMAIN cp sites/default/default.settings.php sites/$AEGIR_DOMAIN/settings.php chmod g+w sites/$AEGIR_DOMAIN/settings.php mkdir sites/$AEGIR_DOMAIN/files chmod 2770 sites/$AEGIR_DOMAIN/files chgrp www-data sites/$AEGIR_DOMAIN/settings.php chgrp www-data sites/$AEGIR_DOMAIN/files ) Now point your browser to ``http://$AEGIR_DOMAIN/``, select the hostmaster install profile, enter the database credentials you setup above and then the installer will prompt you to secure the permissions on the settings.php file again. chmod g-w sites/$AEGIR_DOMAIN/settings.php You may need to edit your local hosts file to get the aegir domain to work if you have not already added a DNS record for this. On OS X: http://decoding.wordpress.com/2009/04/06/how-to-edit-the-hosts-file-in-mac-os-x-leopard/ Follow the wizard ----------------- You should now be in the installation wizard. The wizard is usually self-documenting so you should just be able to follow the instructions in the wizard to configure Aegir to properly use the webserver and database server. You may need to adjust CentOS's firewall settings to allow HTTP traffic on port 80. If you installed CentOS with a UI, enable "Firewall settings -- WWW (HTTP)". Multiple web servers ------------------ This is best explained here: http://groups.drupal.org/node/21966