forked from MarkUsProject/Markus
-
Notifications
You must be signed in to change notification settings - Fork 0
/
INSTALL
193 lines (154 loc) · 7.67 KB
/
INSTALL
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
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
__ __ _ _ _
| \/ | __ _ _ __| | _| | | |___
| |\/| |/ _` | '__| |/ / | | / __|
| | | | (_| | | | <| |_| \__ \
|_| |_|\__,_|_| |_|\_\\___/|___/
Thanks for using MarkUs!
NOTE: If you are a MarkUs developer, please follow setup instructions here:
https://stanley.cdf.toronto.edu/drproject/csc49x/olm_rails#dev-setup
1. WHAT YOU NEED TO KNOW
MarkUs is a Web application using the Ruby on Rails framework. By design, MarkUs
supports one course per installation. I.e. two different courses require two
installed instances of MarkUs. Please keep that in mind for the following
installation process.
2. DOWNLOAD MARKUS
You can download MarkUs from our website
see http://www.markusproject.org/download/
3. INSTALLATION INSTRUCTIONS
3.1 REQUIRED SOFTWARE
As mentioned previously, MarkUs is a Ruby on Rails application. General
requirements are as follows (Note: MarkUs also works using Phusion Passenger):
* Ruby (version 1.8.7 and higher)
* Ruby development package (required for compiling Ruby PostgreSQL drivers)
* net/https Ruby library (libopenssl-ruby Debian package)
* RDoc (required for Gem)
* Debian 'build-essential' equivalent packages (gcc, make, libc6-dev, etc.)
These packages are required for building PostgreSQL/MySQL gem packages
* Subversion including Ruby bindings
* Gem (version 1.3 and higher)
* The following Ruby gems:
- rails (version 2.3.8)
- daemons (version 1.0.10 and higher)
- mongrel (version 1.1.5 and higher)
- mongrel_cluster (version 1.0.5 and higher)
- fastercsv (version 1.4.0 and higher)
- rake (version 0.8.7 and higher)
- ruby-debug (in case you want to debug MarkUs)
- will_paginate (version 2.3.11 and higher)
- rubyzip (version 1.3.6 and higher)
- ya2yaml (version 0.29.2 and higher)
* Apache httpd (version 2.2 and higher) including the following modules:
- mod_proxy
- mod_rewrite
- mod_dav_svn (required if you want to allow SVN repository access)
- mod_authz_svn (required if you want to allow SVN repository access)
* ImageMagick (known to work with >=6.5.7, older versions should be ok too)
Only required if you plan to be able to view and annotate pdfs within
the browser (PDF_SUPPORT setting in config files)
DATABASE
We know that MarkUs works with either PostgreSQL or MySQL databases.
MarkUs/PostgreSQL:
If you plan to use MarkUs with a PostgreSQL database, you need the following
software
* PostgreSQL
* Development package(s) for PostgreSQL
* Ruby gems:
- ruby-pg (version 0.7.9.2008.01.28 and higher)
- postgres (version 0.7.9.2008.01.28 and higher)
MarkUs/MySQL:
If you plan to use MarkUs with a MySQL database, you need the following
software
* MySQL
* Development package(s) for MySQL
* Ruby gems:
- mysql (version 2.8.1 and higher)
If you are using a Debian based Linux distribution (such as Ubuntu) you could
install the above required software by using commands similar to the
following:
PostgreSQL option:
sudo aptitude install ruby ruby-dev rdoc libopenssl-ruby postgresql \
libpq-dev subversion libsvn-ruby apache2 libapache2-svn
MySQL option:
sudo aptitude install ruby ruby-dev rdoc mysql-server libmysqlclient15-dev \
suversion libsvn-ruby libopenssl-ruby apache2 libapache2-svn
Installing gem (version 1.3 and higher) on Debian based systems (see
http://stanley.cdf.toronto.edu/drproject/csc49x/olm_rails/wiki/UpdateRailsDebian)
Download rubygems from rubyforge.org (see
http://rubyforge.org/projects/rubygems/); We show the steps for version
1.3.1:
wget http://rubyforge.org/frs/download.php/45905/rubygems-1.3.1.tgz
tar -xzf rubygems-1.3.1.tgz
cd rubygems-1.3.1
sudo ruby setup.rb
sudo mv /usr/bin/gem /usr/bin/gem.old # if you have an older gem version
installed
sudo ln -s /usr/bin/gem1.8 /usr/bin/gem
The above required Ruby gems can, then, be installed like so:
PostgreSQL option:
sudo gem install rails daemons mongrel mongrel_cluster ruby-pg postgres
fastercsv rake ruby-debug will_paginate
MySQL option:
sudo gem install rails daemons mongrel mongrel_cluster mysql
fastercsv rake ruby-debug will_paginate
ImageMagick:
You most likely already have this installed, to make sure you do, simply run
`identify --version` to see if ImageMagick is installed on your machine.
Otherwise, http://www.imagemagick.org/script/install-source.php#unix
has detailed instructions on installing ImageMagick.
3.2 INSTALLING MARKUS
Once you have the required software installed, it should be pretty straight-
forward to install MarkUs. We assume you have a database user with appropriate
permissions set up.
* Get a copy of the MarkUs tarball:
wget http://www.markusproject.org/download/markus-latest-stable.tar.gz
* Extract the tarball to the desired location
tar -xzvf markus-latest-stable.tar.gz
* You should have a directory called markus-X.Y.Z now. Change to MarkUs'
application root. For example:
cd markus-0.9.0
* Set environment variable RAILS_ENV (assumes BASH)
export RAILS_ENV="production"
* In case you are using Rails > 2.3.8 comment out the line containing
RAILS_GEM_VERSION="2.3.8" in config/environment.rb
* Configure database connection settings to match your settings
PostgreSQL option:
cp config/database.yml.postgresql config/database.yml
MySQL option:
cp config/database.yml.mysql config/database.yml
* Configure MarkUs to match your requirements. Please have a look at
config/environments/production.rb. This file is well documented and
your instance specific configuration has to be done in there. If you
have questions, please feel free to get in touch with us:
* Create the database for MarkUs
rake db:create
* Load the database schema for MarkUs
rake db:schema:load
* Create an instructor (for initial login)
rake markus:instructor first_name="test" last_name="test" \
user_name="markus"
* Configure Apache httpd (optional, see example config below)
* Configure Mongrel servers (config/mongrel_cluster.yml)
* Once MarkUs boots up fine (script/server runs without errors), you can start
the mongrel cluster
mongrel_rails cluster::start
see log files (log/mongrel.800x.log) for success/failure messages
* That's it!
If you run into any problems please send e-mail to [email protected].
We are happy to help and would also like to hear your feedback! Please include
the version number of MarkUs you are using. You can find out about the version
you are currently using by issuing the following command:
rake -s markus:version
4. FURTHER INSTRUCTIONS, FAQ, LINKS
* https://stanley.cdf.toronto.edu/drproject/csc49x/olm_rails/wiki/InstallProdStable
* https://stanley.cdf.toronto.edu/drproject/csc49x/olm_rails/wiki/InstallProdFaq
* https://stanley.cdf.toronto.edu/drproject/csc49x/olm_rails/wiki/MultipleHosting
* http://www.markusproject.org/dev/markus_httpd_vhost.conf
* https://stanley.cdf.toronto.edu/drproject/csc49x/olm_rails#dev-setup
* See available rake tasks for MarkUs: "rake -T markus" or more generically
"rake -T"
5. BUGS
If you think you have found a bug, you can file a bug report or contact
developers at [email protected]. Feel free to provide a patch ;-)
https://stanley.cdf.toronto.edu/drproject/csc49x/olm_rails/ticket?action=new (new ticket link)
https://stanley.cdf.toronto.edu/drproject/csc49x/olm_rails/query (see existing tickets)