45
45
* Creates data directories and subversion repositories for all users, backing
46
46
up directories for any existing users.
48
The script is executed with the following command::
48
The script is executed with the following command from the IVLE source
50
51
sudo ivle-loadsampledata examples/db/sample.sql
53
54
installation. Be sure you wish to do this.
55
56
.. note:: The script may fail at the "dropping database" phase if Apache or
56
another process are using the database. It is best to stop Apache before
57
another process are using the database. It is best to *restart* (not stop)
58
Apache before executing the script (``sudo /etc/init.d/apache2 restart``).
59
60
If the database exists, but is not properly initialised, then the script
60
61
may fail. In this case, you should manually run ``ivle-mountallusers -u``,
63
64
If there are any existing users (including sample users from previous runs
64
65
of the script), their files and subversion repos will be moved out of the
65
66
way to a backup location, ``/var/lib/ivle/jails-removed-<date>/``.
67
If you run this script regularly, your ``/var/lib/ivle/`` will become full
68
of these backups, so you may wish to remove them often. However, they are
69
typically fairly small (a few hundred kilobytes each), because they only
70
contain user content, not the full jail image.
105
There are four users (username/password). Note that in all cases, the password
110
There are five users (username/password). Note that in all cases, the password
108
113
* admin/password: This user has administrative rights over the entire system.
109
114
* lecturer/password: This is a normal user, but is enrolled as a lecturer in
110
100101 (2009 semester 1) and 100102 (2009 semester 2).
111
* studenta/password: This is a normal user, enrolled in 100101 (2009 semester
112
1) and 100102 (2009 semester 2).
113
* studentb/password: This is a normal user, enrolled in 100102 (2009 semester
114
2). This student has not yet accepted the Terms of Service, so does not have
115
ivle-101 (2009 semester 1) and ivle-102 (2009 semester 2).
116
* tutor/password: This is a normal user, but is enrolled as a tutor in
117
ivle-102 (2009 semester 2).
118
* studenta/password: This is a normal user, enrolled in ivle-101 (2009
119
semester 1) and ivle-102 (2009 semester 2).
120
* studentb/password: This is a normal user, enrolled in ivle-102 (2009
121
semester 2). This student has not yet accepted the Terms of Service, so does
122
not have a jail created, etc.
117
124
.. note:: For the first three users, the Subversion password is also
118
125
"password". This means it is possible to access their SVN repository
123
130
When studentb logs in for the first time, his SVN repository is created,
124
131
and given a random password.
136
The repository for user "studenta" has a few sample files. All of the
137
directories must be checked out (using the Checkout button) before the files
138
can be seen from the IVLE application.
140
* :file:`stuff/Welcome to IVLE.html`: A simple web page, which can be
141
displayed with the "Serve" command.
142
* :file:`stuff/hello.py`: A simple Python script, which can be executed with
143
the "Serve" command. This file has a few edits in its revision history.
144
* :file:`ivle-102/mywork/phase1.html`: A file for a student's project
146
* :file:`group1/phase2.html`: A file for a group project submission. This
147
contains edits by both studenta and studentb, and is also accessible if
148
logged in as studentb.
153
The subject ivle-102 (2009 semester 2) has two project sets and three
154
projects. This demonstrates the relationship between project sets and
157
The first project set is a solo project set (every student works by
158
themselves on all projects). It has one project in it.
160
The second project set is a group project set, for groups of 3. That means
161
students work in the *same* group of 3 for every project in the set. It has
162
two projects in it, demonstrating that the students get to keep their group
163
(including all of the group files) across the two projects in this set.
165
Projects 1 and 2 have their due date set in the year 3009, so they will always
166
be submittable. Project 3 was due in 2009, so it has already closed.
168
Finally, there is a single group for projects 2 and 3, which has the students
169
studenta and studentb enlisted.
174
There is currently a single exercise, ``factorial``, which prompts the user to
175
write a factorial function and tests its correctness.
180
There is currently a single worksheet in the subject ivle-102 (2009 semester
181
2). It embeds the exercise ``factorial``.
126
183
Updating the sample data
127
184
========================