~azzar1/unity/add-show-desktop-key

« back to all changes in this revision

Viewing changes to doc/man/sample.rst

  • Committer: mattgiuca
  • Date: 2008-07-15 07:19:34 UTC
  • Revision ID: svn-v3-trunk0:2b9c9e99-6f39-0410-b283-7f802c844ae2:trunk:875
Added "migrations" directory, which contains incremental database update
    scripts.
Updated users.sql, uniqueness key on offering table.
Added migration matching this update to the migrations directory. Mm handy!

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
.. IVLE - Informatics Virtual Learning Environment
2
 
   Copyright (C) 2007-2009 The University of Melbourne
3
 
 
4
 
.. This program is free software; you can redistribute it and/or modify
5
 
   it under the terms of the GNU General Public License as published by
6
 
   the Free Software Foundation; either version 2 of the License, or
7
 
   (at your option) any later version.
8
 
 
9
 
.. This program is distributed in the hope that it will be useful,
10
 
   but WITHOUT ANY WARRANTY; without even the implied warranty of
11
 
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12
 
   GNU General Public License for more details.
13
 
 
14
 
.. You should have received a copy of the GNU General Public License
15
 
   along with this program; if not, write to the Free Software
16
 
   Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
17
 
 
18
 
***********
19
 
Sample data
20
 
***********
21
 
 
22
 
IVLE comes with supplied sample data to give a quick overview of the system.
23
 
This sample data may be installed by an administrative script. It should not
24
 
be installed in a production environment.
25
 
 
26
 
The sample data consists of database entries, for populating sample subjects,
27
 
offerings, users, projects, groups and worksheets, as well as some sample
28
 
files in users' Subversion repositories.
29
 
 
30
 
Installing the sample data
31
 
==========================
32
 
 
33
 
The data is stored in an SQL dump file, in ``examples/db/sample.sql``.
34
 
 
35
 
You must import this data into a **fresh** IVLE database. You can
36
 
re-initialise your database by running ``sudo -u postgres dropdb ivle``, and
37
 
then following the database setup instructions, in the section
38
 
:ref:`database-setup`.
39
 
 
40
 
The data may be imported by running the following command::
41
 
 
42
 
    sudo -u postgres psql ivle < examples/db/sample.sql
43
 
 
44
 
.. XXX
45
 
.. warning:: Instructions on fixing up the user's repositories and file
46
 
   systems to come.
47
 
 
48
 
What is included
49
 
================
50
 
 
51
 
Subjects, semesters and offerings
52
 
---------------------------------
53
 
 
54
 
There are four semesters in the database: 2009 semesters 1 and 2, and 2010
55
 
semesters 1 and 2.
56
 
 
57
 
.. note:: We pretend that we are in 2009 semester 2 (even if that doesn't
58
 
   agree with the system clock). Therefore, 2009 semester 1 is a "past
59
 
   semester", 2009 semester 2 is the "current semester", and the 2010
60
 
   semesters are "future semesters."
61
 
 
62
 
There are four subjects in the database, with subject short names ivle-101,
63
 
ivle-102, ivle-201 and ivle-202.
64
 
 
65
 
The subjects have offerings for some of the semesters, as shown in this table:
66
 
 
67
 
+------+----------+-----------+
68
 
| Year | Semester | Subject   |
69
 
+======+==========+===========+
70
 
| 2009 | 1        | ivle-101  |
71
 
+------+----------+-----------+
72
 
| 2009 | 2        | ivle-102  |
73
 
+------+----------+-----------+
74
 
| 2010 | 1        | ivle-101  |
75
 
+------+----------+-----------+
76
 
| 2010 | 1        | ivle-201  |
77
 
+------+----------+-----------+
78
 
| 2010 | 2        | ivle-102  |
79
 
+------+----------+-----------+
80
 
| 2010 | 2        | ivle-202  |
81
 
+------+----------+-----------+
82
 
 
83
 
Users
84
 
-----
85
 
 
86
 
There are four users (username/password). Note that in all cases, the password
87
 
is "password".
88
 
 
89
 
* admin/password: This user has administrative rights over the entire system.
90
 
* lecturer/password: This is a normal user, but is enrolled as a lecturer in
91
 
  100101 (2009 semester 1) and 100102 (2009 semester 2).
92
 
* studenta/password: This is a normal user, enrolled in 100101 (2009 semester
93
 
  1) and 100102 (2009 semester 2).
94
 
* studentb/password: This is a normal user, enrolled in 100102 (2009 semester
95
 
  2). This student has not yet accepted the Terms of Service, so does not have
96
 
  a jail created, etc.
97
 
 
98
 
.. note:: For the first three users, the Subversion password is also
99
 
   "password". This means it is possible to access their SVN repository
100
 
   with a stand-alone SVN client with that password. This is somewhat
101
 
   unrealistic, as the SVN password in IVLE is usually a randomly-generated
102
 
   string, not related to the user's IVLE login password.
103
 
 
104
 
   When studentb logs in for the first time, his SVN repository is created,
105
 
   and given a random password.
106
 
 
107
 
Updating the sample data
108
 
========================
109
 
 
110
 
For developers: If you need to update the sample data, follow this procedure.
111
 
 
112
 
Run the following command::
113
 
 
114
 
    pg_dump --schema=public --disable-triggers --data-only --column-inserts \
115
 
        --inserts --no-owner ivle > examples/db/sample.sql
116
 
 
117
 
Then check the diff. You may hand-edit the SQL file, but only for the purpose
118
 
of fixing up unsightly data -- it should be possible to reload from the script
119
 
and re-export with no diff.