? 553230.patch
? INSTALL.html
Index: INSTALL.txt
===================================================================
RCS file: /cvs/drupal-contrib/contributions/profiles/hostmaster/INSTALL.txt,v
retrieving revision 1.30
diff -r1.30 INSTALL.txt
1c1
< -*-rst-*-
---
> .. This document is formatted using the ReST syntax.
3,4c3,5
< This document describes briefly how to install a multi-platform,
< single-server Aegir Drupal provisionning system. 
---
> =================================
>  Aegir Installation Instructions
> =================================
6c7,9
< This document is formatted using the ReST syntax.
---
> ------------------------------------------------------------------------------------------------------------------
>  This document describes briefly how to install a multi-platform, single-server Aegir Drupal provisionning system.
> ------------------------------------------------------------------------------------------------------------------
8,9d10
< Aegir 0.2 requirements
< ======================
11,12c12,30
< This section describes what is expected of the servers Aegir is
< running on.
---
> Aegir requirements
> ==================
> 
> This section describes what is expected of the servers Aegir is running
> on.
> 
> Aegir must run some UNIX flavour because the majority of functionality
> in this system occurs in the back-end, through command line scripting.
> There are also several features (such as symlinks), that are not
> available to users on Windows. There are no plans currently to add
> windows support.
> 
> The level of access required to be able to configure this system is
> very far beyond what is commonly available to users with shared hosting.
> 
> Following instructions will provide example commands for a Debian-like
> distribution. They are assumed to be run as root user. Prefix them with
> sudo if you are working with a privileges user instead of root.
> 
24,28c42,43
< That webserver should probably run some UNIX flavour because the
< majority of functionality in this system occurs in the back-end,
< through command line scripting. There are also several features (such
< as symlinks), that are not available to users on Windows. There are no
< plans currently to add windows support.
---
> Shell commands:
> ::
30d44
< Shell commands::
32a47
> 
40c55,57
< Shell commands::
---
> Shell commands:
> ::
> 
43,44d59
< MySQL server
< ------------
46,48c61,76
< You will require a MySQL server, obviously. It is preferable to use a
< dedicated server since Aegir will create MySQL users, since it will
< require a "root" MySQL user.
---
> Database server
> ---------------
> 
> You will require a database server, obviously. Aegir currently only 
> supports MySQL. It is preferable to use a dedicated server since Aegir 
> will create database users and will require a privileged user.
> 
> New sites database names and users will have the form ``site_$nid``, where
> $nid is the node id of the site being created (Aegir create sites as
> nodes).
> 
> Shell commands:
> ::
> 
>  apt-get install mysql-server
> 
53,64c81,86
< Aegir requires an MTA (Mail Transfer Agent) installed on your
< webserver in order to be able to install a new site to your new
< platform. If you don't have an MTA you the site installation will fail
< with message like "could not send email." Additional messages will
< show that site has been removed because of this problem. To remedy the
< situation simply install an MTA like sendmail, postfix, or exim and do
< the minimal configuration.  On Debian-based systems do:
< 
< Shell commands::
<  sudo apt-get install postfix
<     
< Once that is done you should be able to install a site to the new platform. 
---
> Aegir requires an MTA (Mail Transfer Agent) installed on your webserver
> in order to be able to install new sites to your new platform. If you
> don't have an MTA you the site installation will fail with message like
> "could not send email". Additional messages will show that site has been
> removed because of this problem. To remedy the situation simply install
> an MTA like sendmail, postfix, or exim and do the minimal configuration.
66,67c88,136
< Other requirements
< ------------------
---
> Shell commands:
> ::
> 
>  apt-get install postfix
> 
> 
> Aegir user
> ----------
> 
> The provision framework of Aegir requires that the scripts run as a 
> non-root system account, to ensure that it can correctly set the file
> permissions on the hosted files. 
> 
> Also to ensure that the file permissions of the hosted sites are
> always as safe as can be, and especially to make sure that the web
> server does not have the ability to modify the code of the site, the
> configured system account needs to be a member of the web server group,
> in order to be able to correctly set the file permissions.
> 
> More detailed instructions on this topic will be given later in the web 
> installation wizard.
> 
> This document assumes the Aegir user is ``aegir``, its home directory is
> ``/var/aegir`` and the webserver group is ``www-data``. You can choose
> another username if desired.
> 
> In addition we will create a directory layout for Aegir configuration
> and backups.
> 
> Shell commands:
> ::
> 
>  adduser --system --home /var/aegir --ingroup www-data aegir
>  mkdir -p /var/aegir/config/vhost.d
>  mkdir -p /var/aegir/backups
>  chmod -R 0700 /var/aegir/{config,backups}
>  chown -R aegir /var/aegir/*
> 
> 
> CVS commands
> ------------
> 
> If you want to install Aegir from CVS you will need to install ``cvs``
> command in the server system.
> 
> Shell commands:
> ::
> 
>  apt-get install cvs
69,71d137
< * never run drush as root. aegir is designed to be ran as its own user.
< * the "aegir directory" (/var/aegir) *must* be the home directory of
<   that user (the "aegir user", below)
73,74c139,140
< Aegir 0.2 installation instructions
< ===================================
---
> Aegir installation instructions
> ===============================
80,82c146,149
< This document assumes the Aegir home is in /var/aegir, adapt as desired,
< but make sure that the user you create (as suggested in the install
< wizard) has this directory configured as its home directory.
---
> You can choose to install Aegir from CVS or by using drush. Checking out
> Aegir's code from CVS allows you to easily update to future newer
> versions. If you prefer drush, make sure the versions reported in the
> output seem right.
84,85c151,154
< Checking out the code
< ---------------------
---
> Installation instructions presents you in each step both
> alternative instructions to checkout from CVS or download with drush 
> each component of Aegir. Be warned that in the hours following a new
> release, drush will not catch up the correct versions.
87,88c156,157
< This assumes you have installed CVS. Those commands should be ran as the
< aegir user and assume it can write to /var/aegir.
---
> All instructions and in general all commands must be run as aegir user,
> so all permissions are always set correctly.
89a159,195
> To become aegir user depends on your system configuration: if you have
> root password (usually debian) or alternatively you have a privileged
> user with sudo (usually ubuntu).
> 
> If you have root password:
> ::
> 
>  su -c "su -s /bin/bash aegir"
> 
> If you have sudo privileges:
> ::
> 
>  sudo -u aegir bash
> 
> Aditionally to make following instructions generic and not dependant on
> a concrete Drupal or Aegir version. We will use bash environment
> variables for this. So current Drupal is 6.13 and Aegir release
> is 0.3-RC3.
> You should replace following command for current versions at the time
> you are reading this document.
> 
> Shell commands:
> ::
> 
>   export DRUPAL_DIR=/var/aegir/drupal-6.13
>   export AEGIR_TAG=DRUPAL-6--0-3-RC3
> 
> 
> Installing drush 2.0
> --------------------
> 
> At the time this document is being written current drush stable version
> is 2.0. Perhaps a newer version does exist and this document is not
> updated yet.
> 
> Shell commands for cvs:
> ::
91,93d196
< Shell commands::
<  export CVSROOT=:pserver:anonymous:anonymous@cvs.drupal.org:/cvs/drupal
<  mkdir /var/aegir
94a198
>  export CVSROOT=:pserver:anonymous:anonymous@cvs.drupal.org:/cvs/drupal
97,111c201,288
<  cd .drush && /var/aegir/drush/drush.php dl provision
<  cd ../
<  /var/aegir/drush/drush.php dl drupal
<  cd drupal-6.*
<  cvs co -d profiles/hostmaster -rDRUPAL-6--0-3 contributions/profiles/hostmaster
<  cd profiles/hostmaster
<  /var/aegir/drush/drush.php dl hosting install_profile_api 
< 
< We still use CVS to checkout the hostmaster profile because drush has
< problems downloading profiles: http://drupal.org/node/500324
< 
< The above should install version 2.1 of install_profile_api and the
< proper versions (0.3) of the hosting, hostmaster and provision
< projets. Make sure the versions reported by drush in the output seem
< right.
---
> 
> Shell commands for package download:
> ::
> 
>  cd /var/aegir
>  wget http://ftp.drupal.org/files/projects/drush-All-Versions-2.0.tar.gz
>  tar -xvzf drush-All-Versions-2.0.tar.gz
>  mkdir .drush
> 
> Aditionally we will export another envorinment variable for the purpose
> of referencing drush executable in a shorter way.
> 
> Shell commands:
> ::
> 
>   export DRUSH=/var/aegir/drush/drush.php
> 
> 
> Downloading provision framework
> -------------------------------
> 
> The provision framework is not a drupal module but a drush extension. So
> it must be placed in ``/var/aegir/.drush`` for drush to be able to find it.
> 
> Shell commands for cvs:
> ::
> 
>  cvs co -d .drush/provision -r$AEGIR_TAG contributions/modules/provision
> 
> Shell commands for drush:
> ::
> 
>  $DRUSH dl provision --destination=.drush
> 
> 
> Installing drupal
> -----------------
> 
> Drush is able to download latest version of Drupal. Be sure that the
> downloaded version is the same you put in $DRUPAL_DIR in above.
> 
> Shell commands:
> ::
> 
>  $DRUSH dl drupal
>  cd $DRUPAL_DIR
> 
> 
> Installing hostmaster profile
> -----------------------------
> 
> Shell commands for cvs:
> ::
> 
>  cvs co -d profiles/hostmaster -r$AEGIR_TAG contributions/profiles/hostmaster
>  
> Shell commands for drush:
> ::
> 
>  $DRUSH dl --destination=./profiles hostmaster
> 
> 
> Installing hosting module
> -------------------------
> 
> Shell commands for cvs:
> ::
> 
>  cvs co -d profiles/hostmaster/modules/hosting -r$AEGIR_TAG contributions/modules/hosting
> 
> Shell commands for drush:
> ::
> 
>  mkdir profiles/hostmaster/modules
>  $DRUSH dl --destination=./profiles/hostmaster/modules hosting
> 
> 
> Installing install_profile_api module
> -------------------------------------
> 
> Hostmaster profile depends on Install Profile API module version 2.1. 
> Following command will force to download correct version.
> 
> Shell commands:
> ::
> 
>  $DRUSH dl --destination=./profiles/hostmaster/modules install_profile_api-6.x-2.1
> 
116,117c293,318
< Aegir now has its own theme which you can use. It is also suggested
< that you install admin_menu to ease administration.
---
> Aegir has its own theme which you can use. Theme is called Eldir. It is
> also suggested that you install admin_menu to ease administration.
> 
> 
> Installing Eldir theme
> ~~~~~~~~~~~~~~~~~~~~~~
> 
> Shell commands for cvs:
> ::
> 
>  cvs co -d profiles/hostmaster/modules/hosting -r$AEGIR_TAG contributions/themes/eldir
>  
> Shell commands for drush:
> ::
> 
>  mkdir profiles/hostmaster/themes
>  $DRUSH dl --destination=$DRUPAL_DIR/profiles/hostmaster/themes eldir
> 
> 
> Installing Admin menu module
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> 
> Shell commands:
> ::
> 
>  $DRUSH dl --destination=$DRUPAL_DIR/profiles/hostmaster/modules admin_menu
119,127d319
< Note that now your drush installation should be up and running so you
< can start using it to download modules directly. This is how
< admin_menu is installed below. The theme is installed using CVS
< because the release may not yet be available when you read this
< document.
< 
< Shell commands::
<  cd drupal-6.*/profiles/hostmaster
<  /var/aegir/drush/drush.php dl eldir admin_menu
132,140c324,325
< Those instructions assume you are running Debian specific and
< installing aegir in http://aegir.example.com. If you are running
< another system you basically need to:
< 
<  1. create a directory for Aegir configs
<  2. activate the mod_rewrite engine
<  3. include the Aegir apache configurations in Apache
<  4. create a base configuration file for Aegir in /var/aegir/config/vhost.d/aegir.example.com
<  5. restart apache
---
> Those instructions assume you are installing aegir in http://aegir.example.com
> If you are running another non-Debian system you basically need to:
142c327,372
< So this needs to be ran as root too.
---
>  1. create a virtual host for Aegir in /var/aegir/config/vhost.d/aegir.example.com
>  2. include the Aegir apache configurations in Apache
>  3. activate the mod_rewrite engine
>  4. restart apache
> 
> Note some of those instructions must be run as a privileged user (root)
> instead of Aegir's user.
> 
> 
> Creating Aegir's virtualhost
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> 
> Hostmaster provides an example virtualhost for apache. Copy it to Aegir's
> virtual hosts directory and modify it to suit your needs, particularly 
> the path leading to the Drupal core ($DRUPAL_DIR in the examples above).
> 
> That virtual host is a special one that includes a ``NameVirtualHost``
> directive for ``*:80``. Debian uses to provide such a directive in 
> ``/etc/apache2/ports.conf``. Other distributions may include it directly 
> in ``httpd.conf``. If your apache server already include such a directive,
> you may comment it out in Aegir's main virtual host.
> 
> 
> Shell commands:
> ::
> 
>  cp profiles/hostmaster/apache2.conf.txt ../config/vhost.d/aegir.example.com
>  # edit and configure
> 
> 
> Configuring Aegir in Apache
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~
> 
> Aegir VirtualHosts for Apache are stored at ``/var/aegir/config/vhost.d``
> (if you have not changed default locations). So Apache must be instruct
> to read configurations from there. In Debian systems each configuration
> file located at ``/etc/apache2/conf.d`` is read on inilialization. If you
> are using another system, you can put ``Include /var/aegir/config/vhost.d``
> in a file inside /etc/httpd/conf.d/ or directly at the end of httpd.conf.
> 
> Aditionally rewrite module must be enabled and apache restarted.
> 
> Following commands are to be run as root.
> 
> Shell commands:
> ::
144,146d373
< Shell commands::
<  cd /var/aegir
<  mkdir -p config/vhost.d/
149,150d375
<  echo "NameVirtualHost *:80" >> /etc/apache2/conf.d/aegir
<  cp drupal-6.*/profiles/hostmaster/apache2.conf.txt config/vhost.d/aegir.example.com
153,155d377
< You MUST modify the config/vhost.d/aegir.example.com to suit your
< needs (particularly the path leading to the Drupal core
< (/var/aegir/drupal-6.* in the example above).
165,174c387,398
< /var/aegir/drupal-6.13
< /var/aegir/drupal-6.13/profiles/hostmaster
< /var/aegir/drupal-6.13/profiles/hostmaster/modules/hosting
< /var/aegir/drupal-6.13/profiles/hostmaster/modules/install_profile_api
< /var/aegir/drupal-6.13/profiles/hostmaster/themes/eldir
< /var/aegir/drupal-6.13/sites/aegir.example.com
< /var/aegir/config/vhost.d
< /var/aegir/backups
< /var/aegir/drush/drush.php
< /var/aegir/.drush/provision
---
> ::
> 
>  /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
177c401
< package works out of /usr/bin/drush and that's fine), but you are
---
> package works out of ``/usr/bin/drush`` and that's fine), but you are
180a405
> 
188c413,415
< SQL commands::
---
> SQL commands:
> ::
> 
193a421,437
> 
> DNS Configuration
> -----------------
> 
> Configuring DNS is up to you. Currently Aegir does nothing with DNS. 
> 
> As a help trick, if you are installing Aegir in local to try ant test
> it, you can do local DNS by adding entries to file ``/etc/hosts``. First
> line of this file looks like:
> 
> ``127.0.0.1  localhost your-machine-name``
> 
> Simply add all domains you want to this line. Ej:
> 
> ``127.0.0.1  localhost your-machine-name aegir.example.com other1 other2``
> 
> 
197,211c441,471
< Now you are ready to install the first Drupal using this installation
< profile. Point your browser to http://aegir.example.com/ , assuming
< DNS is properly configured to point to your webserver, otherwise you
< may want to try http://localhost/ .
< 
< The installer is going to complain about the missing settings.php. It
< is recommended that you create the aegir site as a real site.
< 
< Shell commands::
<  mkdir drupal-6.*/sites/aegir.example.com
<  chmod a+w drupal-6.*/sites/aegir.example.com/settings.php
< 
< 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:
---
> 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.
> 
> Shell commands:
> ::
> 
>  mkdir sites/aegir.example.com
>  cp sites/default/default.settings.php sites/aegir.example.com/settings.php
>  chmod g+w sites/aegir.example.com/settings.php
>  mkdir sites/aegir.example.com/files
>  chmod 2770 sites/aegir.example.com/files
> 
> Now point your browser to ``http://aegir.example.com/``, 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:
> 
> Shell commands:
> ::
> 
>  chmod a-w sites/aegir.example.com/settings.php
>  chmod a-w sites/aegir.example.com/settings.php
>  chmod a-w sites/aegir.example.com/settings.php
213,214d472
< Shell commands::
<  chmod a-w /var/aegir/drupal-6.*/sites/aegir.example.com/settings.php
223a482
> 
227c486
< To deploy new platforms to provisions site to, you simply need to
---
> To deploy new platforms to provision sites to, you simply need to
232,234c491,496
< Shell commands::
<  cd /var/aegir
<  ./drush/drush.php dl drupal
---
> Shell commands:
> ::
> 
>  cd ..
>  $DRUSH dl drupal-5.x
>  $DRUSH dl drupal-7.x
236d497
< Use "drush dl drupal-5.x" to get the latest release of the 5.x branch.
Index: hostmaster.forms.inc
===================================================================
RCS file: /cvs/drupal-contrib/contributions/profiles/hostmaster/hostmaster.forms.inc,v
retrieving revision 1.5
diff -r1.5 hostmaster.forms.inc
34c34
< 
---
> /*
56c56
< 
---
> */
