| 1 | #!perl |
1 | #!perl |
| 2 | ################################################################################ |
2 | ################################################################################ |
| 3 | # WeBWorK Online Homework Delivery System |
3 | # WeBWorK Online Homework Delivery System |
| 4 | # Copyright © 2000-2003 The WeBWorK Project, http://openwebwork.sf.net/ |
4 | # Copyright © 2000-2003 The WeBWorK Project, http://openwebwork.sf.net/ |
| 5 | # $CVSHeader: webwork-modperl/conf/global.conf.dist,v 1.80 2004/06/26 20:40:17 jj Exp $ |
5 | # $CVSHeader: webwork-modperl/conf/global.conf.dist,v 1.81 2004/07/01 20:31:13 dpvc Exp $ |
| 6 | # |
6 | # |
| 7 | # This program is free software; you can redistribute it and/or modify it under |
7 | # This program is free software; you can redistribute it and/or modify it under |
| 8 | # the terms of either: (a) the GNU General Public License as published by the |
8 | # the terms of either: (a) the GNU General Public License as published by the |
| 9 | # Free Software Foundation; either version 2, or (at your option) any later |
9 | # Free Software Foundation; either version 2, or (at your option) any later |
| 10 | # version, or (b) the "Artistic License" which comes with this package. |
10 | # version, or (b) the "Artistic License" which comes with this package. |
| … | |
… | |
| 25 | # $webworkURLRoot base URL handled by Apache::WeBWorK |
25 | # $webworkURLRoot base URL handled by Apache::WeBWorK |
| 26 | # $pgRoot directory that contains the PG distribution |
26 | # $pgRoot directory that contains the PG distribution |
| 27 | # $courseName name of the course being used |
27 | # $courseName name of the course being used |
| 28 | |
28 | |
| 29 | ################################################################################ |
29 | ################################################################################ |
| 30 | # WeBWorK settings |
30 | # System-wide locations (directories and URLs) |
| 31 | ################################################################################ |
31 | ################################################################################ |
| 32 | |
32 | |
| 33 | %webworkDirs = ( |
33 | # The root directory, set by webwork_root variable in Apache configuration. |
| 34 | root => "$webworkRoot", |
34 | $webworkDirs{root} = "$webworkRoot"; |
| 35 | DATA => "$webworkRoot/DATA", |
35 | |
| 36 | uploadCache => "$webworkRoot/DATA/uploads", |
36 | # Location of system-wide data files. |
| 37 | bin => "$webworkRoot/bin", |
37 | $webworkDirs{DATA} = "$webworkDirs{root}/DATA"; |
| 38 | conf => "$webworkRoot/conf", |
38 | |
| 39 | courses => "$webworkRoot/courses", |
39 | # Used for temporary storage of uploaded files. |
| 40 | htdocs => "$webworkRoot/htdocs", |
40 | $webworkDirs{uploadCache} = "$webworkDirs{DATA}/uploads"; |
| 41 | htdocs_temp => "$webworkRoot/htdocs/tmp", |
41 | |
| 42 | equationCache => "$webworkRoot/htdocs/tmp/equations", |
42 | # Location of utility programs. |
| 43 | local_help => "$webworkRoot/htdocs/helpFiles", |
43 | $webworkDirs{bin} = "$webworkDirs{root}/bin"; |
| 44 | lib => "$webworkRoot/lib", |
44 | |
| 45 | logs => "$webworkRoot/logs", |
45 | # Location of configuration files, templates, snippets, etc. |
|
|
46 | $webworkDirs{conf} = "$webworkDirs{root}/conf"; |
|
|
47 | |
|
|
48 | # Location of course directories. |
|
|
49 | $webworkDirs{courses} = "$webworkDirs{root}/courses"; |
|
|
50 | |
|
|
51 | # Contains the WeBWorK libraries. (FIXME: not used) |
|
|
52 | #$webworkDirs{lib} = "$webworkDirs{root}/lib"; |
|
|
53 | |
|
|
54 | # Contains log files. |
|
|
55 | $webworkDirs{logs} = "$webworkDirs{root}/logs"; |
|
|
56 | |
|
|
57 | # Location of PG macros. (FIXME: not used) |
| 46 | macros => "$pgRoot/macros", |
58 | #$webworkDirs{macros} = "$pgRoot/macros"; |
| 47 | tmp => "$webworkRoot/tmp", |
|
|
| 48 | ); |
|
|
| 49 | |
59 | |
| 50 | %webworkFiles = ( |
60 | # Contains non-web-accessible temporary files, such as TeX working directories. |
| 51 | environment => "$webworkDirs{conf}/global.conf", |
61 | $webworkDirs{tmp} = "$webworkDirs{root}/tmp"; |
| 52 | hardcopySnippets => { |
|
|
| 53 | preamble => "$webworkDirs{conf}/snippets/hardcopyPreamble.tex", |
|
|
| 54 | setHeader => "$webworkDirs{conf}/snippets/setHeader.pg", # hardcopySetHeader.pg", |
|
|
| 55 | problemDivider => "$webworkDirs{conf}/snippets/hardcopyProblemDivider.tex", |
|
|
| 56 | setFooter => "$webworkDirs{conf}/snippets/hardcopySetFooter.pg", |
|
|
| 57 | setDivider => "$webworkDirs{conf}/snippets/hardcopySetDivider.tex", |
|
|
| 58 | userDivider => "$webworkDirs{conf}/snippets/hardcopyUserDivider.tex", |
|
|
| 59 | postamble => "$webworkDirs{conf}/snippets/hardcopyPostamble.tex", |
|
|
| 60 | }, |
|
|
| 61 | screenSnippets => { |
|
|
| 62 | setHeader => "$webworkDirs{conf}/snippets/setHeader.pg", # screenSetHeader.pg", |
|
|
| 63 | }, |
|
|
| 64 | logs => { |
|
|
| 65 | timing => "$webworkDirs{logs}/timing.log", |
|
|
| 66 | }, |
|
|
| 67 | # Set this to "" if you don't want to use the equation cache file |
|
|
| 68 | equationCacheDB => "$webworkDirs{DATA}/equationcache", |
|
|
| 69 | ); |
|
|
| 70 | |
62 | |
| 71 | %webworkURLs = ( |
63 | ##### The following locations are web-accessible. |
|
|
64 | |
|
|
65 | # The root URL (usually /webwork2), set by <Location> in Apache configuration. |
| 72 | root => "$webworkURLRoot", |
66 | $webworkURLs{root} = "$webworkURLRoot"; |
| 73 | home => "/webwork2_files/index.html", |
67 | |
|
|
68 | # Location of system-wide web-accessible files, such as equation images, and |
|
|
69 | # help files. |
|
|
70 | $webworkDirs{htdocs} = "$webworkDirs{root}/htdocs"; |
| 74 | htdocs => "/webwork2_files", |
71 | $webworkURLs{htdocs} = "/webwork2_files"; |
| 75 | htdocs_temp => "/webwork2_files/tmp", |
72 | |
| 76 | equationCache => "/webwork2_files/tmp/equations", |
73 | # The URL of the static WeBWorK home page (FIXME: not used) |
|
|
74 | #$webworkURLs{home} = "$webworkURLs{htdocs}/index.html"; |
|
|
75 | |
|
|
76 | # Location of web-accessible temporary files, such as equation images. |
|
|
77 | $webworkDirs{htdocs_temp} = "$webworkDirs{htdocs}/tmp"; |
|
|
78 | $webworkURLs{htdocs_temp} = "$webworkURLs{htdocs}/tmp"; |
|
|
79 | |
|
|
80 | # Location of cached equation images. |
|
|
81 | $webworkDirs{equationCache} = "$webworkDirs{htdocs_temp}/equations"; |
|
|
82 | $webworkURLs{equationCache} = "$webworkURLs{htdocs_temp}/equations"; |
|
|
83 | |
|
|
84 | # Contains context-sensitive help files. |
|
|
85 | $webworkDirs{local_help} = "$webworkDirs{htdocs}/helpFiles"; |
|
|
86 | $webworkURLs{local_help} = "$webworkURLs{htdocs}/helpFiles"; |
|
|
87 | |
|
|
88 | # URL of general WeBWorK documentation. |
| 77 | docs => "http://webhost.math.rochester.edu/webworkdocs/docs", |
89 | $webworkURLs{docs} = "http://webhost.math.rochester.edu/webworkdocs/docs"; |
| 78 | local_help => "/webwork2_files/helpFiles", |
90 | |
|
|
91 | # URL of WeBWorK 1.x profLogin.pl script, for access to old professor pages. |
|
|
92 | # Note that both systems must share a single "courses" directory for this to be |
|
|
93 | # useful. Leave this blank to disable |
| 79 | oldProf => "/webwork1/profLogin.pl", |
94 | $webworkURLs{oldProf} = "/webwork1/profLogin.pl"; |
|
|
95 | |
|
|
96 | # URL of WeBWorK Bugzilla database. |
| 80 | bugReporter => "http://bugs.webwork.rochester.edu/enter_bug.cgi?product=WeBWorK%20mod_perl", |
97 | $webworkURLs{bugReporter} = "http://bugs.webwork.rochester.edu/enter_bug.cgi?product=WeBWorK%20mod_perl"; |
| 81 | jsMath => "/webwork2_files/jsMath/jsMath.js", |
98 | |
|
|
99 | # Location of jsMath script, used for the jsMath display mode. |
|
|
100 | $webworkURLs{jsMath} = "$webworkURLs{root}/jsMath/jsMath.js"; |
|
|
101 | |
|
|
102 | # Location of ASCIIMathML script, used for the asciimath display mode. |
| 82 | asciimath => "/webwork2_files/ASCIIMathML/ASCIIMathML.js", |
103 | $webworkURLs{asciimath} = "$webworkURLs{root}/ASCIIMathML/ASCIIMathML.js"; |
| 83 | ); |
|
|
| 84 | |
104 | |
| 85 | ################################################################################ |
105 | ################################################################################ |
| 86 | # Default course-specific settings |
106 | # Defaults for course-specific locations (directories and URLs) |
| 87 | ################################################################################ |
107 | ################################################################################ |
| 88 | |
108 | |
|
|
109 | # The root directory of the current course. (The ID of the current course is |
|
|
110 | # available in $courseName.) |
| 89 | my $courseRoot = "$webworkDirs{courses}/$courseName"; |
111 | $courseDirs{root} = "$webworkDirs{courses}/$courseName"; |
| 90 | %courseDirs = ( |
|
|
| 91 | root => "$courseRoot", |
|
|
| 92 | DATA => "$courseRoot/DATA", |
|
|
| 93 | auth_DATA => "$courseRoot/DATA/.auth", |
|
|
| 94 | html => "$courseRoot/html", |
|
|
| 95 | html_images => "$courseRoot/html/images", |
|
|
| 96 | html_temp => "$courseRoot/html/tmp", |
|
|
| 97 | logs => "$courseRoot/logs", |
|
|
| 98 | scoring => "$courseRoot/scoring", |
|
|
| 99 | templates => "$courseRoot/templates", |
|
|
| 100 | macros => "$courseRoot/templates/macros", |
|
|
| 101 | email => "$courseRoot/templates/email", |
|
|
| 102 | ); |
|
|
| 103 | |
112 | |
| 104 | %courseFiles = ( |
113 | # Location of course-specific data files, such as WW1 (GDBM) database files. |
|
|
114 | $courseDirs{DATA} = "$courseDirs{root}/DATA"; |
|
|
115 | |
|
|
116 | # Location of authentication data files when using a WW1 (GDBM) database. |
|
|
117 | $courseDirs{auth_DATA} = "$courseDirs{DATA}/.auth"; |
|
|
118 | |
|
|
119 | # Location of course HTML files, passed to PG. |
|
|
120 | $courseDirs{html} = "$courseDirs{root}/html"; |
|
|
121 | $courseURLs{html} = "/webwork2_course_files/$courseName"; |
|
|
122 | #$courseURLs{root} = $courseURLs{html}; # FIXME: not used |
|
|
123 | |
|
|
124 | # Location of course image files, passed to PG. |
|
|
125 | $courseDirs{html_images} = "$courseDirs{html}/images"; |
|
|
126 | |
|
|
127 | # Location of web-accessible, course-specific temporary files, like static and |
|
|
128 | # dynamically-generated PG graphics. |
|
|
129 | $courseDirs{html_temp} = "$courseDirs{html}/tmp"; |
|
|
130 | $courseURLs{html_temp} = "$courseURLs{html}/tmp"; |
|
|
131 | |
|
|
132 | # Location of course-specific logs, like the transaction log. |
|
|
133 | $courseDirs{logs} = "$courseDirs{root}/logs"; |
|
|
134 | |
|
|
135 | # Location of scoring files. |
|
|
136 | $courseDirs{scoring} = "$courseDirs{root}/scoring"; |
|
|
137 | |
|
|
138 | # Location of PG templates and set definition files. |
|
|
139 | $courseDirs{templates} = "$courseDirs{root}/templates"; |
|
|
140 | |
|
|
141 | # Location of course-specific macro files. |
|
|
142 | $courseDirs{macros} = "$courseDirs{templates}/macros"; |
|
|
143 | |
|
|
144 | # Location of mail-merge templates. |
|
|
145 | $courseDirs{email} = "$courseDirs{templates}/email"; |
|
|
146 | |
|
|
147 | ################################################################################ |
|
|
148 | # System-wide files |
|
|
149 | ################################################################################ |
|
|
150 | |
|
|
151 | # Location of this file. |
|
|
152 | $webworkFiles{environment} = "$webworkDirs{conf}/global.conf"; |
|
|
153 | |
|
|
154 | # Flat-file database used to protect against MD5 hash collisions. TeX equations |
|
|
155 | # are hashed to determine the name of the image file. There is a tiny chance of |
|
|
156 | # a collision between two TeX strings. This file allows for that. However, this |
|
|
157 | # is slow, so most people chose not to worry about it. Set this to "" if you |
|
|
158 | # don't want to use the equation cache file. |
|
|
159 | $webworkFiles{equationCacheDB} = ""; # "$webworkDirs{DATA}/equationcache"; |
|
|
160 | |
|
|
161 | ##### Hardcopy snippets are used in constructing a TeX file for hardcopy output. |
|
|
162 | ##### They should contain TeX code unless otherwise noted. |
|
|
163 | |
|
|
164 | # The preamble is the first thing in the TeX file. |
|
|
165 | $webworkFiles{hardcopySnippets}{preamble} = "$webworkDirs{conf}/snippets/hardcopyPreamble.tex"; |
|
|
166 | |
|
|
167 | # The setHeader preceeds each set. It is a PG file. |
|
|
168 | $webworkFiles{hardcopySnippets}{setHeader} = "$webworkDirs{conf}/snippets/setHeader.pg"; |
|
|
169 | |
|
|
170 | # The problem divider goes between problems. |
|
|
171 | $webworkFiles{hardcopySnippets}{problemDivider} = "$webworkDirs{conf}/snippets/hardcopyProblemDivider.tex"; |
|
|
172 | |
|
|
173 | # The set footer goes after each set. Is is a PG file. |
|
|
174 | $webworkFiles{hardcopySnippets}{setFooter} = "$webworkDirs{conf}/snippets/hardcopySetFooter.pg"; |
|
|
175 | |
|
|
176 | # The set divider goes between sets (in multiset output). |
|
|
177 | $webworkFiles{hardcopySnippets}{setDivider} = "$webworkDirs{conf}/snippets/hardcopySetDivider.tex"; |
|
|
178 | |
|
|
179 | # The user divider does between users (in multiuser output). |
|
|
180 | $webworkFiles{hardcopySnippets}{userDivider} = "$webworkDirs{conf}/snippets/hardcopyUserDivider.tex"; |
|
|
181 | |
|
|
182 | # The postabmle is the last thing in the TeX file. |
|
|
183 | $webworkFiles{hardcopySnippets}{postamble} = "$webworkDirs{conf}/snippets/hardcopyPostamble.tex"; |
|
|
184 | |
|
|
185 | ##### Screen snippets are used when displaying problem sets on the screen. |
|
|
186 | |
|
|
187 | # The set header is displayed on the problem set page. It is a PG file. |
|
|
188 | $webworkFiles{screenSnippets}{setHeader} = "$webworkDirs{conf}/snippets/setHeader.pg"; |
|
|
189 | |
|
|
190 | ################################################################################ |
|
|
191 | # Course-specific files |
|
|
192 | ################################################################################ |
|
|
193 | |
|
|
194 | # The course configuration file. |
| 105 | environment => "$courseDirs{root}/course.conf", |
195 | $courseFiles{environment} = "$courseDirs{root}/course.conf"; |
|
|
196 | |
|
|
197 | # The message of the day, displayed after login. (FIXME: not used) |
| 106 | motd => "$courseDirs{templates}/motd.txt", |
198 | #$courseFiles{motd} = "$courseDirs{templates}/motd.txt"; |
| 107 | logs => { |
|
|
| 108 | answer_log => "$courseDirs{logs}/answer_log", |
|
|
| 109 | }, |
|
|
| 110 | course_info => "course_info.txt", # path relative to templates directory |
|
|
| 111 | login_info => "login_info.txt", # path relative to templates directory |
|
|
| 112 | ); |
|
|
| 113 | |
199 | |
| 114 | # |
200 | # File contents are displayed after login, on the problem sets page. Path given |
|
|
201 | # here is relative to the templates directory. |
|
|
202 | $courseFiles{course_info} = "course_info.txt"; |
|
|
203 | |
|
|
204 | # File contents are displayed on the login page. Path given here is relative to |
|
|
205 | # the templates directory. |
|
|
206 | $courseFiles{login_info} = "login_info.txt"; |
|
|
207 | |
| 115 | # Additional library buttons can be added to the Library Browser (SetMaker.pm) |
208 | # Additional library buttons can be added to the Library Browser (SetMaker.pm) |
| 116 | # by adding the libraries you want to the following line. For each key=>value |
209 | # by adding the libraries you want to the following line. For each key=>value |
| 117 | # in the list, if a directory (or link to a directory) with name 'key' appears |
210 | # in the list, if a directory (or link to a directory) with name 'key' appears |
| 118 | # in the templates directory, then a button with name 'value' will be placed at |
211 | # in the templates directory, then a button with name 'value' will be placed at |
| 119 | # the top of the problem browser. (No button will appear if there is no directory |
212 | # the top of the problem browser. (No button will appear if there is no |
| 120 | # or link with the given name in the templates directory.) For example, |
213 | # directory or link with the given name in the templates directory.) For |
| 121 | # |
214 | # example, |
|
|
215 | # |
| 122 | # $courseFiles{problibs} = {rochester => "Rochester", asu => "ASU"}; |
216 | # $courseFiles{problibs} = {rochester => "Rochester", asu => "ASU"}; |
| 123 | # |
217 | # |
| 124 | # would add two buttons, one for the Rochester library and one for the ASU |
218 | # would add two buttons, one for the Rochester library and one for the ASU |
| 125 | # library, provided templates/rochester and templates/asu exists. |
219 | # library, provided templates/rochester and templates/asu exists. |
| 126 | # |
220 | # |
| 127 | $courseFiles{problibs} = {}; |
221 | $courseFiles{problibs} = {}; |
| 128 | |
222 | |
|
|
223 | ################################################################################ |
|
|
224 | # Logs |
|
|
225 | ################################################################################ |
| 129 | |
226 | |
| 130 | # quick hack to fix transaction logging. blah. |
227 | # FIXME: take logs out of %webworkFiles/%courseFiles and give them their own |
|
|
228 | # top-level hash. |
|
|
229 | |
|
|
230 | # Logs data about how long it takes to process problems. (Do not confuse this |
|
|
231 | # with the /other/ timing log which can be set by WeBWorK::Timing and is used |
|
|
232 | # for benchmarking system performance in general. At some point, this timing |
|
|
233 | # mechanism will be deprecated in favor of the WeBWorK::Timing mechanism.) |
|
|
234 | $webworkFiles{logs}{timing} = "$webworkDirs{logs}/timing.log"; |
|
|
235 | |
|
|
236 | # The transaction log contains data from each recorded answer submission. This |
|
|
237 | # is useful if the database becomes corrupted. |
| 131 | $webworkFiles{logs}->{transaction} = "$courseDirs{logs}/transaction.log"; |
238 | $webworkFiles{logs}{transaction} = "$courseDirs{logs}/transaction.log"; |
|
|
239 | |
|
|
240 | # The past answer list stores a history of all users' submitted answers. (FIXME: not used) |
| 132 | $webworkFiles{logs}->{pastAnswerList} = "$courseDirs{logs}/past_answers.log"; |
241 | $webworkFiles{logs}{pastAnswerList} = "$courseDirs{logs}/past_answers.log"; |
| 133 | |
242 | |
| 134 | my $courseURLRoot = "/webwork2_course_files/$courseName"; |
243 | # The answer log stores a history of all users' submitted answers. |
| 135 | %courseURLs = ( |
244 | $courseFiles{logs}{answer_log} = "$courseDirs{logs}/answer_log"; |
| 136 | root => "$courseURLRoot", |
|
|
| 137 | html => "$courseURLRoot", |
|
|
| 138 | html_temp => "$courseURLRoot/tmp", |
|
|
| 139 | ); |
|
|
| 140 | |
245 | |
| 141 | ################################################################################ |
246 | ################################################################################ |
| 142 | # Other site-specific options |
247 | # Mail settings |
| 143 | ################################################################################ |
248 | ################################################################################ |
| 144 | |
249 | |
| 145 | %mail = ( |
250 | # Mail sent by the PG system and the mail merge and feedback modules will be |
| 146 | smtpServer => "mail.math.rochester.edu", |
251 | # sent via this SMTP server. |
| 147 | smtpSender => "webwork\@math.rochester.edu", |
252 | $mail{smtpServer} = 'mail.yourschool.edu'; |
|
|
253 | |
|
|
254 | # When connecting to the above server, WeBWorK will send this address in the |
|
|
255 | # MAIL FROM command. This has nothing to do with the "From" address on the mail |
|
|
256 | # message. It can really be anything, but some mail servers require it contain |
|
|
257 | # a valid mail domain, or at least be well-formed. |
|
|
258 | $mail{smtpSender} = 'webwork@yourserver.yourschool.edu'; |
| 148 | |
259 | |
| 149 | # allowedRecipients defines addresses that the PG system is allowed to |
260 | # AllowedRecipients defines addresses that the PG system is allowed to send mail |
| 150 | # send mail to. this prevents subtle PG exploits. This should be set |
261 | # to. this prevents subtle PG exploits. This should be set in course.conf to the |
| 151 | # in course.conf to the addresses of professors of each course. Sending |
262 | # addresses of professors of each course. Sending mail from the PG system (i.e. |
| 152 | # mail from the PG system (i.e. questionaires, essay questions) will |
263 | # questionaires, essay questions) will fail if this is not set somewhere (either |
| 153 | # fail if this is not set somewhere (either here or in course.conf). |
264 | # here or in course.conf). |
| 154 | #allowedRecipients => [ |
265 | $mail{allowedRecipients} = [ |
| 155 | # 'prof1@host.yourdomain.edu', |
266 | #'prof1@yourserver.yourdomain.edu', |
| 156 | # 'prof2@host.yourdomain.edu', |
267 | #'prof2@yourserver.yourdomain.edu', |
| 157 | #], |
268 | ]; |
| 158 | |
269 | |
| 159 | # if defined, feedbackRecipients overrides the list of recipients for |
270 | # If defined, feedbackRecipients overrides the list of recipients for feedback |
| 160 | # feedback email. It's appropriate to set this in the course.conf for |
271 | # email. It's appropriate to set this in the course.conf for specific courses, |
| 161 | # specific courses, but probably not in global.conf. if not defined, |
272 | # but probably not in global.conf. if not defined, mail is sent to all |
| 162 | # mail is sent to all professors and TAs for a given course |
273 | # professors and TAs for a given course |
| 163 | #feedbackRecipients => [ |
274 | $mail{feedbackRecipients} = [ |
| 164 | # 'prof1@host.yourdomain.edu', |
275 | #'prof1@yourserver.yourdomain.edu', |
| 165 | # 'prof2@host.yourdomain.edu', |
276 | #'prof2@yourserver.yourdomain.edu', |
| 166 | #], |
277 | ]; |
| 167 | |
278 | |
| 168 | # feedbackVerbosity: |
279 | # feedbackVerbosity: |
| 169 | # 0: send only the feedback comment and context link |
280 | # 0: send only the feedback comment and context link |
| 170 | # 1: as in 0, plus user, set, problem, and PG data |
281 | # 1: as in 0, plus user, set, problem, and PG data |
| 171 | # 2: as in 1, plus the problem environment (debugging data) |
282 | # 2: as in 1, plus the problem environment (debugging data) |
| 172 | feedbackVerbosity => 1, |
283 | $mail{feedbackVerbosity} = 1; |
| 173 | |
284 | |
| 174 | # defines the size of the Mail Merge editor window |
285 | # Defines the size of the Mail Merge editor window |
| 175 | # FIXME: should this be here? it's UI, not mail |
286 | # FIXME: should this be here? it's UI, not mail |
| 176 | # FIXME: replace this with the auto-size method that TWiki uses |
287 | # FIXME: replace this with the auto-size method that TWiki uses |
| 177 | editor_window_rows => 15, |
288 | $mail{editor_window_rows} = 15; |
| 178 | editor_window_columns => 100, |
289 | $mail{editor_window_columns} = 100; |
| 179 | ); |
|
|
| 180 | |
290 | |
| 181 | %externalPrograms = ( |
291 | ################################################################################ |
| 182 | mkdir => "/bin/mkdir", |
292 | # Paths to external programs |
| 183 | tth => "/usr/local/bin/tth", |
293 | ################################################################################ |
|
|
294 | |
|
|
295 | $externalPrograms{mkdir} = "/bin/mkdir"; |
|
|
296 | $externalPrograms{mysql} = "/usr/local/bin/mysql"; |
|
|
297 | |
|
|
298 | $externalPrograms{latex} = "/usr/local/bin/latex"; |
| 184 | pdflatex => "/usr/local/bin/pdflatex", |
299 | $externalPrograms{pdflatex} = "/usr/local/bin/pdflatex"; |
| 185 | latex => "/usr/local/bin/latex", |
300 | $externalPrograms{dvipng} = "/usr/local/bin/dvipng"; |
| 186 | dvipng => "/usr/local/bin/dvipng", |
301 | $externalPrograms{tth} = "/usr/local/bin/tth"; |
|
|
302 | |
|
|
303 | # These image conversion utilities are included in the WeBWorK distribution. |
| 187 | gif2eps => "$webworkDirs{bin}/gif2eps", |
304 | $externalPrograms{gif2eps} = "$webworkDirs{bin}/gif2eps"; |
| 188 | png2eps => "$webworkDirs{bin}/png2eps", |
305 | $externalPrograms{png2eps} = "$webworkDirs{bin}/png2eps"; |
| 189 | gif2png => "$webworkDirs{bin}/gif2png", |
306 | $externalPrograms{gif2png} = "$webworkDirs{bin}/gif2png"; |
| 190 | mysql => "/usr/local/bin/mysql", |
|
|
| 191 | ); |
|
|
| 192 | |
307 | |
| 193 | %siteDefaults = ( |
308 | ################################################################################ |
| 194 | status => { |
309 | # Site defaults (FIXME: what other things could be "site defaults"?) |
|
|
310 | ################################################################################ |
|
|
311 | |
|
|
312 | # Status strings -- lists valid status values and their names. If your site uses |
|
|
313 | # additional values, add them here. |
|
|
314 | $siteDefaults{status} = { |
|
|
315 | A => "Audit", |
| 195 | audit => "Audit", |
316 | audit => "Audit", |
| 196 | A => "Audit", |
317 | D => "Drop", |
| 197 | drop => "Drop", |
318 | drop => "Drop", |
| 198 | D => "Drop", |
|
|
| 199 | withdraw => "Drop", |
319 | withdraw => "Drop", |
|
|
320 | C => "Enrolled", |
| 200 | current => "Enrolled", |
321 | current => "Enrolled", |
| 201 | C => "Enrolled", |
|
|
| 202 | enrolled => "Enrolled", |
322 | enrolled => "Enrolled", |
| 203 | }, |
323 | }; |
| 204 | ); |
|
|
| 205 | |
324 | |
| 206 | ################################################################################ |
325 | ################################################################################ |
| 207 | # Frontend options |
326 | # Frontend options |
| 208 | ################################################################################ |
327 | ################################################################################ |
| 209 | |
328 | |
| … | |
… | |
| 218 | # Several database are defined in the file conf/database.conf and stored in the |
337 | # Several database are defined in the file conf/database.conf and stored in the |
| 219 | # hash %dbLayouts. |
338 | # hash %dbLayouts. |
| 220 | include "conf/database.conf"; |
339 | include "conf/database.conf"; |
| 221 | |
340 | |
| 222 | # Select the default database layout. This can be overridden in the course.conf |
341 | # Select the default database layout. This can be overridden in the course.conf |
| 223 | # file of a particular course. |
342 | # file of a particular course. If you choose "gdbm", WeBWorK will be able to |
|
|
343 | # use courses from WeBWorK 1 without first adding course.conf files to them. |
|
|
344 | # However, the recommended database layout for new courses is "sql". This can |
|
|
345 | # be set when creating a course. |
| 224 | #$dbLayoutName = "sql"; |
346 | $dbLayoutName = "sql"; # or: "gdbm" |
| 225 | $dbLayoutName = "gdbm"; |
|
|
| 226 | |
347 | |
|
|
348 | # This sets the symbol "dbLayout" as an alias for the selected database layout. |
| 227 | *dbLayout = $dbLayouts{$dbLayoutName}; |
349 | *dbLayout = $dbLayouts{$dbLayoutName}; |
| 228 | |
350 | |
| 229 | ################################################################################ |
351 | ################################################################################ |
| 230 | # Problem library options |
352 | # Problem library options |
| 231 | ################################################################################ |
353 | ################################################################################ |
| 232 | |
354 | |
| 233 | %problemLibrary = ( |
355 | # The directory containing the problem library files. Set to "" if no problem |
| 234 | root => "", # set to the top of the problem library, if its installed |
356 | # library is installed. |
| 235 | sourceSQL => "ProblemLibrary", |
357 | $problemLibrary{root} = ""; |
| 236 | userSQL => "webworkRead", |
358 | |
| 237 | passwordSQL => "", |
359 | # The name of the SQL database containing problem metadata |
| 238 | ); |
360 | $problemLibrary{sourceSQL} = "ProblemLibrary"; |
|
|
361 | |
|
|
362 | # The user name to use when connecting to the problem library database |
|
|
363 | $problemLibrary{userSQL} = "webworkRead"; |
|
|
364 | |
|
|
365 | # The password to use when connecting to the problem library database |
|
|
366 | $problemLibrary{passwordSQL} = ""; |
| 239 | |
367 | |
| 240 | ################################################################################ |
368 | ################################################################################ |
| 241 | # Authorization system |
369 | # Authorization system |
| 242 | ################################################################################ |
370 | ################################################################################ |
| 243 | |
371 | |
| 244 | # This lets you specify a minimum permission level needed to perform certain |
372 | # This lets you specify a minimum permission level needed to perform certain |
| 245 | # actions. In the current system, >=10 will allow a professor to perform the |
373 | # actions. In the current system, >=10 will allow a professor to perform the |
| 246 | # action, >=5 will allow a TA to, and >=0 will allow a student to perform an |
374 | # action, >=5 will allow a TA to, and >=0 will allow a student to perform an |
| 247 | # action (almost never what you want). |
375 | # action (almost never what you want). |
|
|
376 | |
| 248 | my $student = 0; |
377 | my $student = 0; |
| 249 | my $ta = 5; |
378 | my $ta = 5; |
| 250 | my $professor = 10; |
379 | my $professor = 10; |
|
|
380 | |
| 251 | %permissionLevels = ( |
381 | %permissionLevels = ( |
| 252 | report_bugs => $student, |
382 | report_bugs => $student, |
| 253 | view_multiple_sets => $ta, |
383 | view_multiple_sets => $ta, |
| 254 | view_unopened_sets => $ta, |
384 | view_unopened_sets => $ta, |
| 255 | view_unpublished_sets => $ta, |
385 | view_unpublished_sets => $ta, |
| … | |
… | |
| 291 | # kindof a backdoor to the practice user system, since he doesn't have a |
421 | # kindof a backdoor to the practice user system, since he doesn't have a |
| 292 | # password. Come to think of it, why do we even have this?! |
422 | # password. Come to think of it, why do we even have this?! |
| 293 | #$debugPracticeUser = "practice666"; |
423 | #$debugPracticeUser = "practice666"; |
| 294 | |
424 | |
| 295 | ################################################################################ |
425 | ################################################################################ |
| 296 | # PG translation options |
426 | # PG subsystem options |
| 297 | ################################################################################ |
427 | ################################################################################ |
| 298 | |
428 | |
| 299 | %pg = ( |
429 | # List of enabled display modes. Comment out any modes you don't wish to make |
| 300 | # available display modes |
430 | # available for use. |
| 301 | displayModes => [ qw(plainText formattedText images jsMath asciimath) ], |
431 | $pg{displayModes} = [ |
| 302 | # pg options |
432 | "plainText", # display raw TeX for math expressions |
| 303 | options => { |
433 | "formattedText", # format math expressions using TtH |
| 304 | # default translation options |
434 | "images", # display math expressions as images generated by dvipng |
|
|
435 | "jsMath", # render TeX math expressions on the client side using jsMath |
|
|
436 | "asciimath", # render TeX math expressions on the client side using ASCIIMathML |
|
|
437 | ]; |
|
|
438 | |
|
|
439 | #### Default settings for the PG translator |
|
|
440 | |
|
|
441 | # Default display mode. Should be listed above. |
| 305 | displayMode => "images", |
442 | $pg{options}{displayMode} = "images"; |
| 306 | showOldAnswers => 1, |
443 | |
| 307 | showCorrectAnswers => 0, |
444 | # The default grader to use, if a problem doesn't specify. |
| 308 | showHints => 0, |
445 | $pg{options}{grader} = "avg_problem_grader"; |
| 309 | showSolutions => 0, |
446 | |
| 310 | catchWarnings => 0, # there's a global warning catcher now |
447 | # Fill in answer blanks with the student's last answer by default? |
| 311 | # default grader |
448 | $pg{options}{showOldAnswers} = 1; |
| 312 | grader => "avg_problem_grader", |
449 | |
|
|
450 | # Show correct answers (when allowed) by default? |
|
|
451 | $pg{options}{showCorrectAnswers} = 0; |
|
|
452 | |
|
|
453 | # Show hints (when allowed) by default? |
|
|
454 | $pg{options}{showHints} = 0; |
|
|
455 | |
|
|
456 | # Show solutions (when allowed) by default? |
|
|
457 | $pg{options}{showSolutions} = 0; |
|
|
458 | |
|
|
459 | # Catch translation warnings internally by default? (We no longer need to do |
|
|
460 | # this, since there is a global warnings handler. So this should be off.) |
|
|
461 | $pg{options}{catchWarnings} = 0; |
|
|
462 | |
|
|
463 | ##### Currently-selected renderer |
|
|
464 | |
|
|
465 | # Only the local renderer is supported in this version. |
|
|
466 | $pg{renderer} = "WeBWorK::PG::Local"; |
|
|
467 | |
|
|
468 | # The remote renderer connects to an XML-RPC PG rendering server. |
|
|
469 | #$pg{renderer} = "WeBWorK::PG::Remote"' |
|
|
470 | |
|
|
471 | ##### Renderer-dependent options |
|
|
472 | |
|
|
473 | # The remote renderer has one option: |
|
|
474 | $pg{renderers}{"WeBWorK::PG::Remote"} = { |
|
|
475 | # The "proxy" server to connect to for remote rendering. |
|
|
476 | proxy => "http://localhost:21000/RenderD", |
|
|
477 | }; |
|
|
478 | |
|
|
479 | ##### Settings for various display modes |
|
|
480 | |
|
|
481 | # "images" mode has several settings: |
|
|
482 | $pg{displayModeOptions}{images} = { |
|
|
483 | # Determines the method used to align images in output. Can be |
|
|
484 | # "baseline", "absmiddle", or "mysql". |
|
|
485 | dvipng_align => 'baseline', |
|
|
486 | |
|
|
487 | # If we choose mysql, we need information on connecting to the |
|
|
488 | # database. Whatever you use here, you have to create the database |
|
|
489 | # and grant read/write priveleges to the user listed here. To create |
|
|
490 | # the database in mysql, as root use: |
|
|
491 | # |
|
|
492 | # CREATE DATABASE DvipngDepths; |
|
|
493 | # USE DvipngDepths; |
|
|
494 | # CREATE TABLE depths (md5 CHAR(33) NOT NULL, depth SMALLINT, PRIMARY KEY (md5)); |
|
|
495 | # GRANT ALL ON DvipngDepths.* TO webworkWrite; |
|
|
496 | # |
|
|
497 | # In the last statement, "webworkWrite" should match the user below. |
|
|
498 | dvipng_depth_db => { |
|
|
499 | dbsource => 'dbi:mysql:DvipngDepths', |
|
|
500 | user => $dbLayouts{sql}->{password}->{params}->{usernameRW}, |
|
|
501 | passwd => $dbLayouts{sql}->{password}->{params}->{passwordRW}, |
| 313 | }, |
502 | }, |
| 314 | # options for various renderers |
503 | }; |
| 315 | renderers => { |
|
|
| 316 | "WeBWorK::PG::Remote" => { |
|
|
| 317 | proxy => "http://localhost:21000/RenderD" |
|
|
| 318 | }, |
|
|
| 319 | |
504 | |
| 320 | # next can be baseline, absmiddle, or mysql |
|
|
| 321 | dvipng_align => 'baseline', |
|
|
| 322 | |
|
|
| 323 | # if we choose mysql, we need information on connecting |
|
|
| 324 | # to the database. Whatever you use here, you have to |
|
|
| 325 | # create the database and grant read/write priveleges to |
|
|
| 326 | # the user listed here |
|
|
| 327 | # To create the database in mysql, as root use: |
|
|
| 328 | |
|
|
| 329 | # create database DvipngDepths; |
|
|
| 330 | # use DvipngDepths; |
|
|
| 331 | # create table depths ( md5 char(33) not null, depth smallint, PRIMARY KEY (md5)) ; |
|
|
| 332 | # grant ALL on DvipngDepths.* to webworkWrite; |
|
|
| 333 | |
|
|
| 334 | # In the last statement, "webworkWrite" should match the |
|
|
| 335 | # user below |
|
|
| 336 | |
|
|
| 337 | dvipng_depth_db => { |
|
|
| 338 | dbsource => 'dbi:mysql:DvipngDepths', |
|
|
| 339 | user => $dbLayouts{sql}->{password}->{params}->{usernameRW}, |
|
|
| 340 | passwd => $dbLayouts{sql}->{password}->{params}->{passwordRW}, |
|
|
| 341 | } |
|
|
| 342 | }, |
|
|
| 343 | # currently selected renderer |
|
|
| 344 | renderer => "WeBWorK::PG::Local", |
|
|
| 345 | #renderer => "WeBWorK::PG::Remote", |
|
|
| 346 | # directories used by PG |
505 | ##### Directories used by PG |
| 347 | directories => { |
506 | |
| 348 | # directories used only by PG |
507 | # The root of the PG directory tree (from pg_root in Apache config). |
| 349 | root => "$pgRoot", |
508 | $pg{directories}{root} = "$pgRoot"; |
| 350 | lib => "$pgRoot/lib", |
509 | $pg{directories}{lib} = "$pg{directories}{root}/lib"; |
| 351 | macros => "$pgRoot/macros", |
510 | $pg{directories}{macros} = "$pg{directories}{root}/macros"; |
| 352 | }, |
511 | |
| 353 | # this can be customized in the course.conf file |
512 | ##### "Special" PG environment variables. (Stuff that doesn't fit in anywhere else.) |
| 354 | specialPGEnvironmentVars => { |
513 | |
| 355 | PRINT_FILE_NAMES_FOR => [ qw(professor) ], |
514 | # Users for whom to print the file name of the PG file being processed. |
|
|
515 | $pg{specialPGEnvironmentVars}{PRINT_FILE_NAMES_FOR} = [ "professor", ]; |
|
|
516 | |
|
|
517 | # Locations of CAPA resources. (Only necessary if you need to use converted CAPA |
|
|
518 | # problems.) |
| 356 | CAPA_Tools => "$courseDirs{macros}/CAPA_Tools/", |
519 | $pg{specialPGEnvironmentVars}{CAPA_Tools} = "$courseDirs{macros}/CAPA_Tools/", |
| 357 | CAPA_MCTools => "$courseDirs{macros}/CAPA_MCTools/", |
520 | $pg{specialPGEnvironmentVars}{CAPA_MCTools} = "$courseDirs{macros}/CAPA_MCTools/", |
|
|
521 | $pg{specialPGEnvironmentVars}{CAPA_GraphicsDirectory} = "$courseDirs{html}/CAPA_Graphics/", |
| 358 | CAPA_Graphics_URL => "$courseURLs{html}/CAPA_Graphics/", |
522 | $pg{specialPGEnvironmentVars}{CAPA_Graphics_URL} = "$courseURLs{html}/CAPA_Graphics/", |
| 359 | CAPA_GraphicsDirectory => "$courseDirs{html}/CAPA_Graphics/", |
523 | |
| 360 | onTheFlyImageSize => 400, |
524 | # Size in pixels of dynamically-generated images, i.e. graphs. |
| 361 | }, |
525 | $pg{specialPGEnvironmentVars}{onTheFlyImageSize} = 400, |
| 362 | # modules lists module names and the packages each contains |
526 | |
| 363 | modules => [ |
527 | ##### PG modules to load |
|
|
528 | |
|
|
529 | # The first item of each list is the module to load. The remaining items are |
|
|
530 | # additional packages to import. |
|
|
531 | |
|
|
532 | ${pg}{modules} = [ |
| 364 | [qw(DynaLoader)], |
533 | [qw(DynaLoader)], |
| 365 | [qw(Exporter)], |
534 | [qw(Exporter)], |
| 366 | [qw(GD)], |
535 | [qw(GD)], |
| 367 | |
536 | |
| 368 | [qw(AlgParser AlgParserWithImplicitExpand Expr ExprWithImplicitExpand)], |
537 | [qw(AlgParser AlgParserWithImplicitExpand Expr ExprWithImplicitExpand)], |
| 369 | [qw(AnswerHash AnswerEvaluator)], |
538 | [qw(AnswerHash AnswerEvaluator)], |
| 370 | [qw(WWPlot)], # required by Circle (and others) |
539 | [qw(WWPlot)], # required by Circle (and others) |
| 371 | [qw(Circle)], |
540 | [qw(Circle)], |
| 372 | [qw(Complex)], |
541 | [qw(Complex)], |
| 373 | [qw(Complex1)], |
542 | [qw(Complex1)], |
| 374 | [qw(Distributions)], |
543 | [qw(Distributions)], |
| 375 | [qw(Fraction)], |
544 | [qw(Fraction)], |
| 376 | [qw(Fun)], |
545 | [qw(Fun)], |
| 377 | [qw(Hermite)], |
546 | [qw(Hermite)], |
| 378 | [qw(Label)], |
547 | [qw(Label)], |
| 379 | [qw(List)], |
548 | [qw(List)], |
| 380 | [qw(Match)], |
549 | [qw(Match)], |
| 381 | [qw(MatrixReal1)], # required by Matrix |
550 | [qw(MatrixReal1)], # required by Matrix |
| 382 | [qw(Matrix)], |
551 | [qw(Matrix)], |
| 383 | [qw(Multiple)], |
552 | [qw(Multiple)], |
| 384 | [qw(PGrandom)], |
553 | [qw(PGrandom)], |
| 385 | [qw(Regression)], |
554 | [qw(Regression)], |
| 386 | [qw(Select)], |
555 | [qw(Select)], |
| 387 | [qw(Units)], |
556 | [qw(Units)], |
| 388 | [qw(VectorField)], |
557 | [qw(VectorField)], |
| 389 | ], |
558 | ]; |
| 390 | # defaults used by answer evaluators |
559 | |
|
|
560 | ##### Answer evaluatior defaults |
|
|
561 | |
| 391 | ansEvalDefaults => { |
562 | $pg{ansEvalDefaults} = { |
| 392 | functAbsTolDefault => .001, |
563 | functAbsTolDefault => .001, |
| 393 | functLLimitDefault => .0000001, |
564 | functLLimitDefault => .0000001, |
| 394 | functMaxConstantOfIntegration => 1E8, |
565 | functMaxConstantOfIntegration => 1E8, |
| 395 | functNumOfPoints => 3, |
566 | functNumOfPoints => 3, |
| 396 | functRelPercentTolDefault => .1, |
567 | functRelPercentTolDefault => .1, |
| 397 | functULimitDefault => .9999999, |
568 | functULimitDefault => .9999999, |
| 398 | functVarDefault => "x", |
569 | functVarDefault => "x", |
| 399 | functZeroLevelDefault => 1E-14, |
570 | functZeroLevelDefault => 1E-14, |
| 400 | functZeroLevelTolDefault => 1E-12, |
571 | functZeroLevelTolDefault => 1E-12, |
| 401 | numAbsTolDefault => .001, |
572 | numAbsTolDefault => .001, |
| 402 | numFormatDefault => "", |
573 | numFormatDefault => "", |
| 403 | numRelPercentTolDefault => .1, |
574 | numRelPercentTolDefault => .1, |
| 404 | numZeroLevelDefault => 1E-14, |
575 | numZeroLevelDefault => 1E-14, |
| 405 | numZeroLevelTolDefault => 1E-12, |
576 | numZeroLevelTolDefault => 1E-12, |
| 406 | useBaseTenLog => 0, |
577 | useBaseTenLog => 0, |
| 407 | defaultDisplayMatrixStyle => "[s]", |
578 | defaultDisplayMatrixStyle => "[s]", |
| 408 | }, |
579 | }; |
| 409 | ); |
|
|