OK, we have a server with all the required software installed, all we need to do now is install ResourceSpace. This is actually very easy - if you want a quick and dirty installation. The problems arise if we want to ensure the service is resilient and secure, because then we need to install the files on a separate EBS volume, and ideally we need to point MySQL as a separate volume as well.

Because the basic install of ResourceSpace is so simple, we will run through that first.

These instructions assume you have gone through the previous stages and have installed the requisite software (ImageMagick, Subversion, etc.). We use Subversion to install ResourceSpace directly from the RS Subversion server, as follows.

sudo nano /etc/cron.daily/resourcespace.sh

sudo chmod 777 /etc/cron.daily/resourcespace.sh

As noted, this is taken directly from the wiki, and I believe this line is wrong; I would advise you to look at the Chron page for better ways to do this.

We now have a server with ResourceSpace installed, ready to be configured – click here to go to the configuration page.

The RSintheCloud Way

These instructions for installing ResourceSpace are based on the transient nature of cloud computers, so we do not use the default EBS volume for any permanent data. There is also an assumption that you have installed phpMyAdmin and WebMin, and have set up a ResourceSpace user and database.

If you have not already done so, go to the 'adding disk space' section, add another volume, and mount it as /mnt/storage. Follow the instructions to create a ResourceSpace folder and link it as /var/www/RS

We can then follow the instructions given above, with some small variations. Notice the instructions above put ResourceSpace in the root of your website, while these instructions are installing it in the RS folder under the root. This changes a number of the instructions, so please follow one set or the other.

Login to SSH and navigate to the RS folder

cd /var/www/RS

Use Subversion to download the latest version of ResourceSpace from Montala: (note the dot at the end - it's important)

sudo svn co http://svn.montala.net/svn/resourcespace .

When it has finished, create a file store subfolder

sudo mkdir filestore

give the file store universal read/write permissions.

sudo chmod 777 filestore

When we go to configure ResourceSpace, it is going to rewrite the config file. In order to do this it has to have write permission to the 'include' folder, so enter

sudo chmod -R 777 include

Once configuration is complete, we can set this back to 755 (owner can write, others can only read).

just to check that this has worked, we will go to the linked folder on the new volume and check its contents:

cd /mnt/storage

ls -al

cd ResourceSpace

ls -al

Here we can see the typical folder structure for ResourceSpace, saved on our permanent volume.

We now need to set up MySQL. Here it is assumed that you have installed phpMyAdmin and created a ResourceSpace user and database, and also that you have followed the instructions to move the MySQL data files onto the new volume. if you have already done this, there is no more set up for MySQL at this stage, but we will need to make changes in the configuration stage.

Finally, we want to set up Cron, and the easiest way to do this (if you have it installed) is through WebMin.

wget -q -r http://localhost/RS/pages/tools/cron_copy_hitcount.php

Configuring ResourceSpace

Right, we have installed ResourceSpace – either to the default location, or to our new EBS volume – and we have created a new database, either with the default setup, or with a new user and being saved to the new volume. Now it is time to fire up our browser and look at ResourceSpace.

this is slightly different to the instruction given the wiki, because we have installed ResourceSpace in the RS folder – this is to give you space on the server to install other applications or websites. We will discuss later how to set up a sub domain to point to this folder.

The first time you go into ResourceSpace it will automatically run the configurator and check some basic settings:

here you can see (if you can read the red on grey writing) that I have made a mistake setting up my PHP.ini file earlier, so I am just going to go off and fix that first.

Right, I'm back, so let's look at the next section. Below the installation check, we get the basic setting tab:

Here we can see three types of field, those outlined in green, those outlined in red and those with no outline. Whenever we change certain values on this form, the new value will be validated and outlined in green or red as appropriate, so here the configurator has checked there is a MySQL server running on localhost, but needs to know the username and password to log into it. If you have created a ResourceSpace user, enter their details here; otherwise enter the root user password in the password box. Change the database name to have the correct case, and further down change the e-mail from address and e-mail notify to have valid domains. The from address is the address used for sending out messages, so it should match the e-mail settings which you set up earlier. If you have not set these, and your mail does not get delivered, please check the e-mail guide for more information.

The three lines at the bottom of this screen, the spider password and the two scramble keys are used to control access to the images in the file store, or to encrypt data for the API. These have been generated as random strings, and only need changing if you are upgrading an existing ResourceSpace installation when you will need to copy across the old values.

The remaining lines on the page after setting up paths to the various applications used by ResourceSpace, and will not normally need changing. There are also a number of options on the advanced settings tab which should not need changing at the moment, so we can just click the begin installation button, and almost immediately should get a congratulation screen back:

We will now remove write access to the include folder, as suggested – login to SSH and enter:

sudo chmod -R 755 /var/www/RS/include

Or if you have set up a new volume, you can instead change the access on the ResourceSpace folder on the new volume:

sudo chmod -R 755 /mnt/storage/ResourceSpace/include

Right, let's try it:

In your browser, remove the /pages/install.php from the address bar, to leave your-domain/RS and 'go' to give the login screen:

Enter admin as the user and password, and make sure it works. Have a browse around, just make sure it's working.

That's it, for the basic install. There are a couple of quick security bits, and having gone to all that trouble, we want to make a backup - but the hard work is over.

Let's start by changing the admin password, just to stop everybody logging in. Make sure you are logged in, then click on the 'Admin User' link in the top right: