BHL
Archive
This is a read-only archive of the BHL Staff Wiki as it appeared on Sept 21, 2018. This archive is searchable using the search box on the left, but the search may be limited in the results it can provide.

Drupal_installation

Drupal installation notes


Create Postgres Database

bhladmin@bhl-alexandria:~$ sudo -u postgres psql postgres
postgres@bhl-alexandria:~$ CREATE ROLE "fedora" LOGIN PASSWORD 'fedora';
postgres@bhl-alexandria:~$ CREATE DATABASE "fedora" WITH ENCODING='UTF8' OWNER="fedora";
Apache configuration
We create new alias for drupal by editing apache virtual host configuration file : /etc/apache2/sites-available/default
    <Directory "/mnt/nfs-demeter/preingest/drupal-6.19/">
        Options Indexes FollowSymLinks MultiViews
        AllowOverride all
        Order allow,deny
        Allow from all
    </Directory>
 
    ProxyPass /fedora !
Now we have to reload :
/etc/init.d/apache2 reload

Download Drupal

Download the last version of drupal :
wget http://ftp.drupal.org/files/projects/drupal-6.19.tar.gz
Unzip the downloaded archive :
tar xzf drupal-6.19.tar.gz

Create configuration file

Create settings.php file : in drupal-6.19/sites/default folder, make a copy of default.settings.php file to settings.php
cp default.settings.php settings.php
Change the permission on drupal-6.19/sites/default folder and make the settings.php file writable.
chmod a+w sites/default

Drupal installation

We can now start the installation on http://bhl-alexandria.nhm.ac.uk/fedora/. And we have to choose language, inform database information, set the site name and email from which the site will send out mail. You also set the username, email, and password of the first administrator account. Save and continue.
We can change permission on drupal-6.19/sites/default folder and remove write permission on settings.php file.
chmod a-w sites/default

We are ready to login and use our new Drupal site.