55
53
Master versus slave servers
56
54
===========================
58
IVLE is normally deployed in a cluster of several machines, split into
59
two different roles: master and slave.
61
There must be exactly one master server per cluster. The master normally
62
runs the PostgreSQL database server, the Subversion server, and the IVLE User
63
Management Server (``ivle-usrmgt-server``). It might also export shared data
64
directories to the slaves over NFS.
66
There may be any number of slaves in a cluster. They run the IVLE web
67
application, which also starts console host processes. Each slave makes use
68
of the shared services on the master.
70
For a small instance a slave may be run on the same machine as the master.
71
This is the setup described on this page.
74
56
Installing from a Debian package
75
57
================================
80
59
Installing from source
81
60
======================
83
When setting up a development IVLE environment on Ubuntu 9.04 or later,
84
there are scripts to automate most of the process. First get and extract
85
a release, or check out the latest code from the bzr branch: ::
89
This will create a new directory, ``ivle``, containing a pristine
90
source tree. The remaining steps assume that you are in this new
93
The ``ivle-dev-setup`` script will configure PostgreSQL, Apache, IVLE
94
and the filesystem to cooperate, getting you most of the way to a
95
working system in just one step: ::
100
This reconfigures parts of your system, and has the potential to
101
break other applications using Apache or PostgreSQL. It may also
102
fail to execute if you have existing incompatible configurations
106
This may take a few minutes, and will ask you to confirm installation
107
of the dependency packages.
109
Upon completion, you must build a self-contained jail in which to run
110
untrusted user code. ``ivle-dev-setup`` will have configured most of
111
the necessary settings, but you may wish to use a local Ubuntu mirror
112
to improve speed or minimise download costs. If you don't wish to use
113
a special mirror, you may omit the first step. ::
115
sudo ivle-config --jail/mirror http://url.to.mirror/ubuntu
116
sudo ivle-buildjail -r
119
``ivle-buildjail`` will download a large volume of package data --
120
potentially some hundreds of megabytes.
122
``ivle-buildjail`` will download, unpack and install a minimal Ubuntu
123
system and configure it for IVLE usage. This could take a while.
125
Once the jail has been successfully built, IVLE is up and running,
126
but with no user accounts or other data in place. For development
127
or demonstration purposes, sample data (including fictitious users,
128
subjects, and projects) can be loaded.
130
For other environments, it may be more appropriate to start with an
131
empty database and just create users as required.
133
To load the sample data: ::
135
sudo ivle-loadsampledata examples/db/sample.sql
138
If you answer 'yes' to the ``ivle-loadsampledata`` prompt, any
139
existing data in your IVLE database will be **permanently
142
... or to add a new admin user: ::
144
sudo ivle-adduser --admin -p password username 'Full Name'
146
You should then be able to browse to http://ivle.localhost/, and
147
log in with username ``admin`` and password ``password``, or the
148
username and password that you gave to ``ivle-adduser``.
154
If the automatic installation scripts do not work, or if you want more
155
control over the whole process, these manual steps are probably for
156
you. But you need not read this section at all if you were able to log
157
in after following the steps above.
159
.. If this list changes, you also need to change the list above, and
160
the command in bin/ivle-dev-setup.
62
.. If this list changes, you also need to change the list above.
162
64
If you want to grab all of the required packages in one command, use::
164
66
sudo apt-get install apache2 libapache2-mod-python libapache2-svn \
165
67
python2.6 python-cjson python-configobj python-docutils python-epydoc \
166
python-formencode python-genshi python-psycopg2 python-svn python-storm \
167
libjs-jquery postgresql subversion debootstrap rsync build-essential
68
python-formencode python-genshi python-psycopg2 python-svn python-routes \
69
python-storm libjs-jquery postgresql subversion debootstrap rsync \
169
72
While installing from a distribution package is often a better idea for
170
73
users, developers will need to install from a plain source tree.