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

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
# Installation Procedure for IVLE
# ===============================

# Target Machine: Ubuntu (Versions 6.06 and 7.10 - differences between
# versions noted)
#
# IMPORTANT: This is NOT a shell script. It has interactive sections and
# things that need to be customized.
# It is written like a shell script so it can be mostly cut-and-pasted into
# the shell, but it can't simply be executed.

# While other install guides in this package are generic, this one is very
# specific to our intended configuration. It will be very helpful if trying to
# set up IVLE on Ubuntu 7.06 or higher; less helpful for other platforms.
# This refers to ivle.conf, also included.
#
# Author: Matt Giuca
# Date: 29/1/2008

sudo vim /etc/apt/sources.list

# 7.10 (Gutsy) specific #

# Gutsy by default had the CD-ROM packages selected, and the Internet packages
# commented out. (A comment in the apt sources list said it was because it
# failed to verify - IMPORTANT?? Probably not.)
# Comment out line 4 (deb cdrom:...)

# End 7.10 (Gutsy) specific #

# Uncomment ALL the lines for main, restricted and universe
# (deb http:...gutsy main restricted, deb-src ... main restricted
# deb http:...gutsy universe)
# Universe is important for pysvn (python-svn) later on
# :wq

sudo apt-get update

# Apt packages
sudo apt-get install subversion
sudo apt-get install gcc libc6 libc6-dev
# On 6.06 (Dapper):
sudo apt-get install python2.4-dev
# On 7.10 (Gutsy):
sudo apt-get install python2.5-dev

# Python packages needed by IVLE or student code
# See trunk/doc/dependencies.txt
wget 'http://pypi.python.org/packages/source/p/python-cjson/python-cjson-1.0.5.tar.gz'

tar -zxvf python-cjson-1.0.5.tar.gz

cd python-cjson-1.0.5
./setup.py build
sudo ./setup.py install
cd ..

# 6.06 (Dapper) specific
wget 'http://webpy.org/static/web.py-0.22.tar.gz'
tar -zxvf web.py-0.22.tar.gz
cd webpy
python ./setup.py build
sudo python ./setup.py install
cd ..

sudo apt-get install python-svn python-webpy python2.4-gtk2 python-matplotlib
# End 6.06 (Dapper) specific

# 7.10 (Gutsy) specific
sudo apt-get install python-svn python-webpy python-numpy python-matplotlib
# Note: I had a lot of trouble with the python-svn package.
# After playing around a bit it started working.
# python -c 'import pysvn'
# to test if it worked.
# Do Not install python-svn-dbg.
# End 7.10 (Gutsy) specific

# Check out the IVLE trunk
svn co https://ivle.svn.sourceforge.net/svnroot/ivle/trunk ivle_svn
# Says the SourceForge certificate authority is not trusted.
# I chose "Accept (p)ermanently" - Problem??

# NOTE: From this point onwards it is 7.10 (Gutsy) specific. This is because I
# never was able to get IVLE to build with all dependencies on Dapper.

# Set up IVLE
cd ivle_svn
./setup.py listmake
./setup.py config

# "Root directory" - type "/"
# "UID of web server process" - 1000 at this stage (informatics)
# Leave others default.
# Note: This will cause IVLE to get installed to /opt/ivle

./setup.py build
sudo ./setup.py install

# Create a user
sudo ./makeuser.py <username>

# Set up the Apache HTTP server
sudo apt-get install apache2 libapache2-mod-python

# DO: Copy the file "ivle.conf" from this package to
# /etc/apache2/sites-available.
# MODIFY the first few lines so it is specific to your server.

# Replace the existing config link with the ivle one
cd /etc/apache2/sites-enabled/
sudo ln -fs /etc/apache2/sites-available/ivle.conf 000-default

# Restart the server
sudo apache2ctl -k restart

#
# Installing postgres
# ===============================
#
# Some of these instructions follow
#     https://help.ubuntu.com/community/PostgreSQL
# 1. install the base packages

sudo apt-get install postgresql
sudo apt-get install python-pygresql

# Set the postgres user's postgres password
sudo -u postgres psql template1
# At the prompt type (substituting <***password***> with a real one.
ALTER USER postgres WITH ENCRYPTED PASSWORD '<***password***>';
\q

# Create a database
cd <<ivle source directory>>/userdb
sudo -u postgres createdb ivle
sudo -u postgres psql -d ivle < users.sql

#
# Installing Pound
sudo apt-get install pound

# edit /etc/default/pound so that the line reading
#     startup=0
# instead reads
#     startup=1
#
# copy pound.cfg to /etc/pound/pound.cfg