| 1 | #!perl |
1 | #!perl |
| 2 | ################################################################################ |
2 | ################################################################################ |
| 3 | # WeBWorK mod_perl (c) 1995-2002 WeBWorK Team, Univeristy of Rochester |
3 | # WeBWorK mod_perl (c) 1995-2002 WeBWorK Team, Univeristy of Rochester |
| 4 | # $Id: global.conf.dist,v 1.4 2002-12-06 17:50:21 malsyned Exp $ |
4 | # $Id: global.conf.dist,v 1.39 2003-08-04 08:05:50 malsyned Exp $ |
| 5 | ################################################################################ |
5 | ################################################################################ |
| 6 | |
6 | |
| 7 | # This file is used to set up the default WeBWorK course environment for all |
7 | # This file is used to set up the default WeBWorK course environment for all |
| 8 | # requests. Values may be overwritten by the course.conf for a specific course. |
8 | # requests. Values may be overwritten by the course.conf for a specific course. |
| 9 | # All package variables set in this file are added to the course environment. |
9 | # All package variables set in this file are added to the course environment. |
| 10 | # If you wish to set a variable here but omit it from the course environment, |
10 | # If you wish to set a variable here but omit it from the course environment, |
| 11 | # use the "my" keyword. The following variables are available to this file: |
11 | # use the "my" keyword. The following variables are available to this file: |
| 12 | # |
12 | # |
| 13 | # $webworkRoot directory that contains the WeBWorK distribution |
13 | # $webworkRoot directory that contains the WeBWorK distribution |
|
|
14 | # $webworkURL base URL handled by Apache::WeBWorK |
|
|
15 | # $pgRoot directory that contains the PG distribution |
| 14 | # $courseName name of the course being used |
16 | # $courseName name of the course being used |
| 15 | |
17 | |
| 16 | ################################################################################ |
18 | ################################################################################ |
| 17 | # WeBWorK settings |
19 | # WeBWorK settings |
| 18 | ################################################################################ |
20 | ################################################################################ |
| … | |
… | |
| 22 | bin => "$webworkRoot/bin", |
24 | bin => "$webworkRoot/bin", |
| 23 | conf => "$webworkRoot/conf", |
25 | conf => "$webworkRoot/conf", |
| 24 | courses => "$webworkRoot/courses", |
26 | courses => "$webworkRoot/courses", |
| 25 | lib => "$webworkRoot/lib", |
27 | lib => "$webworkRoot/lib", |
| 26 | logs => "$webworkRoot/logs", |
28 | logs => "$webworkRoot/logs", |
| 27 | macros => "$webworkRoot/macros", |
29 | macros => "$pgRoot/macros", |
| 28 | tmp => "$webworkRoot/tmp", |
30 | tmp => "$webworkRoot/tmp", |
| 29 | ); |
31 | ); |
| 30 | |
32 | |
| 31 | %webworkFiles = ( |
33 | %webworkFiles = ( |
| 32 | environment => "$webworkDirs{conf}/global.conf", |
34 | environment => "$webworkDirs{conf}/global.conf", |
| 33 | hardcopySnippets => { |
35 | hardcopySnippets => { |
| 34 | preamble => "$webworkDirs{conf}/hardcopyPreamble.tex", |
36 | preamble => "$webworkDirs{conf}/snippets/hardcopyPreamble.tex", |
| 35 | setHeader => "$webworkDirs{conf}/hardcopySetHeader.pg", |
37 | setHeader => "$webworkDirs{conf}/snippets/hardcopySetHeader.pg", |
| 36 | problemDivider => "$webworkDirs{conf}/hardcopyProblemDivider.tex", |
38 | problemDivider => "$webworkDirs{conf}/snippets/hardcopyProblemDivider.tex", |
| 37 | setFooter => "$webworkDirs{conf}/hardcopySetFooter.pg", |
39 | setFooter => "$webworkDirs{conf}/snippets/hardcopySetFooter.pg", |
| 38 | setDivider => "$webworkDirs{conf}/hardcopySetDivider.tex", |
40 | setDivider => "$webworkDirs{conf}/snippets/hardcopySetDivider.tex", |
|
|
41 | userDivider => "$webworkDirs{conf}/snippets/hardcopyUserDivider.tex", |
| 39 | postamble => "$webworkDirs{conf}/hardcopyPostamble.tex", |
42 | postamble => "$webworkDirs{conf}/snippets/hardcopyPostamble.tex", |
| 40 | }, |
43 | }, |
| 41 | screenSnippets => { |
44 | screenSnippets => { |
| 42 | setHeader => "$webworkDirs{conf}/screenSetHeader.pg", |
45 | setHeader => "$webworkDirs{conf}/snippets/setHeader.pg", |
| 43 | }, |
46 | }, |
| 44 | logs => { |
47 | logs => { |
| 45 | timing => "$webworkDirs{logs}/timing.log", |
48 | timing => "$webworkDirs{logs}/timing.log", |
| 46 | transaction => "$courseDirs{logs}/transaction.log", |
|
|
| 47 | }, |
49 | }, |
| 48 | ); |
50 | ); |
| 49 | |
51 | |
| 50 | my $webworkURLRoot = "/webwork"; # *** # this should be detected! |
|
|
| 51 | %webworkURLs = ( |
52 | %webworkURLs = ( |
| 52 | root => "$webworkURLRoot", |
53 | root => "$webworkURLRoot", |
|
|
54 | home => "/webwork2_files/index.html", |
| 53 | htdocs => "/webwork_files", |
55 | htdocs => "/webwork2_files", |
| 54 | docs => "http://webhost.math.rochester.edu/webworkdocs/docs", |
56 | docs => "http://webhost.math.rochester.edu/webworkdocs/docs", |
| 55 | oldProf => "/webwork-old/profLogin.pl", |
57 | oldProf => "/webwork-old/profLogin.pl", |
| 56 | ); |
58 | ); |
| 57 | |
59 | |
| 58 | ################################################################################ |
60 | ################################################################################ |
| … | |
… | |
| 69 | html_temp => "$courseRoot/html/tmp", |
71 | html_temp => "$courseRoot/html/tmp", |
| 70 | logs => "$courseRoot/logs", |
72 | logs => "$courseRoot/logs", |
| 71 | scoring => "$courseRoot/scoring", |
73 | scoring => "$courseRoot/scoring", |
| 72 | templates => "$courseRoot/templates", |
74 | templates => "$courseRoot/templates", |
| 73 | macros => "$courseRoot/templates/macros", |
75 | macros => "$courseRoot/templates/macros", |
|
|
76 | email => "$courseRoot/templates/email", |
| 74 | ); |
77 | ); |
| 75 | |
78 | |
| 76 | %courseFiles = ( |
79 | %courseFiles = ( |
| 77 | environment => "$courseDirs{root}/course.conf", |
80 | environment => "$courseDirs{root}/course.conf", |
|
|
81 | motd => "$courseDirs{root}/motd.txt", |
|
|
82 | logs => { |
|
|
83 | answer_log => "$courseDirs{logs}/answer_log", |
|
|
84 | }, |
| 78 | ); |
85 | ); |
|
|
86 | |
|
|
87 | # quick hack to fix transaction logging. blah. |
|
|
88 | $webworkFiles{logs}->{transaction} = "$courseDirs{logs}/transaction.log"; |
|
|
89 | $webworkFiles{logs}->{pastAnswerList} = "$courseDirs{logs}/past_answers.log"; |
| 79 | |
90 | |
| 80 | my $courseURLRoot = "$webworkURLs{htdocs}/courses/$courseName"; |
91 | my $courseURLRoot = "$webworkURLs{htdocs}/courses/$courseName"; |
| 81 | %courseURLs = ( |
92 | %courseURLs = ( |
| 82 | base => "$courseURLRoot", # *** # this should be "root"? |
93 | root => "$courseURLRoot", |
| 83 | html => "$courseURLRoot", |
94 | html => "$courseURLRoot", |
| 84 | html_temp => "$courseURLRoot/tmp", |
95 | html_temp => "$courseURLRoot/tmp", |
| 85 | ); |
96 | ); |
| 86 | |
97 | |
| 87 | ################################################################################ |
98 | ################################################################################ |
| … | |
… | |
| 89 | ################################################################################ |
100 | ################################################################################ |
| 90 | |
101 | |
| 91 | %mail = ( |
102 | %mail = ( |
| 92 | smtpServer => "mail.math.rochester.edu", |
103 | smtpServer => "mail.math.rochester.edu", |
| 93 | smtpSender => "webwork\@math.rochester.edu", |
104 | smtpSender => "webwork\@math.rochester.edu", |
|
|
105 | # allowedRecipients defines addresses that the PG system is allowed to |
|
|
106 | # send mail to. this prevents subtle PG exploits. This should be set |
|
|
107 | # in course.conf to the addresses of professors of each course. Sending |
|
|
108 | # mail from the PG system (i.e. questionaires, essay questions) will |
|
|
109 | # fail if this is not set somewhere (either here or in course.conf). |
|
|
110 | #allowedRecipients => [ |
|
|
111 | # "yourname\@host.yourdomain.edu", |
|
|
112 | #], |
|
|
113 | # if defined, feedbackRecipients overrides the list of recipients for |
|
|
114 | # feedback email. It's appropriate to set this in the course.conf for |
|
|
115 | # specific courses, but probably not in global.conf. if not defined, |
|
|
116 | # mail is sent to all professors and TAs for a given course |
|
|
117 | #feedbackRecipients => [ |
|
|
118 | # "prof1\@host.yourdomain.edu", |
|
|
119 | # "prof2\@host.yourdomain.edu", |
|
|
120 | #], |
|
|
121 | # feedbackVerbosity: |
|
|
122 | # 0: send only the feedback comment and context link |
|
|
123 | # 1: as in 0, plus user, set, problem, and PG data |
|
|
124 | # 2: as in 1, plus the problem environment (debugging data) |
|
|
125 | feedbackVerbosity => 1, |
|
|
126 | editor_window_rows => 15, |
|
|
127 | editor_window_columns => 100, |
| 94 | ); |
128 | ); |
| 95 | |
129 | |
| 96 | %externalPrograms = ( |
130 | %externalPrograms = ( |
| 97 | mv => "/bin/mv", # *** is this used? probably not... |
131 | mkdir => "/bin/mkdir", |
| 98 | tth => "/usr/local/bin/tth", |
132 | tth => "/usr/local/bin/tth", |
| 99 | pdflatex => "/usr/local/bin/pdflatex", |
133 | pdflatex => "/usr/local/bin/pdflatex", |
| 100 | latex => "/usr/local/bin/latex", |
134 | latex => "/usr/local/bin/latex", |
| 101 | dvipng => "/usr/local/bin/dvipng -mode ljfivemp -D600 -Q6 -x1000.5 -bgTransparent", |
135 | #dvipng => "/usr/local/bin/dvipng -mode ljfivemp -D600 -Q6 -x1000.5 -bgTransparent", |
|
|
136 | dvipng => "/usr/local/bin/dvipng", |
| 102 | gif2eps => "$webworkDirs{bin}/gif2eps", |
137 | gif2eps => "$webworkDirs{bin}/gif2eps", |
| 103 | png2eps => "$webworkDirs{bin}/png2eps", |
138 | png2eps => "$webworkDirs{bin}/png2eps", |
| 104 | gif2png => "$webworkDirs{bin}/gif2png", |
139 | gif2png => "$webworkDirs{bin}/gif2png", |
| 105 | ); |
140 | ); |
| 106 | |
141 | |
| 107 | ################################################################################ |
142 | ################################################################################ |
| 108 | # Frontend options |
143 | # Frontend options |
| 109 | ################################################################################ |
144 | ################################################################################ |
| 110 | |
145 | |
| 111 | %templates = ( |
146 | %templates = ( |
| 112 | system => "$webworkDirs{conf}/barebones.template", |
147 | system => "$webworkDirs{conf}/templates/ur.template", |
| 113 | ); |
148 | ); |
|
|
149 | |
|
|
150 | ################################################################################ |
|
|
151 | # Database options |
|
|
152 | ################################################################################ |
|
|
153 | |
|
|
154 | # Several database layouts are defined in separate environment files. Select the |
|
|
155 | # one which should be used by all courses by default, and include it. This can |
|
|
156 | # be overridden by including a difference environment file in the course.conf of |
|
|
157 | # a particular course. |
|
|
158 | |
|
|
159 | # Include sql.conf to specify a database layout for use with an SQL server. |
|
|
160 | #include "conf/sql.conf"; |
|
|
161 | |
|
|
162 | # Include gdbm.conf to specify a database layout for WeBWorK 1.x compatible GDBM |
|
|
163 | # databases. Use this layout if you wish to share courses between WeBWorK 1.x |
|
|
164 | # and WeBWorK 2. |
|
|
165 | include "conf/gdbm.conf"; |
|
|
166 | |
|
|
167 | # Please read the documentation in the file that you chose to include, as there |
|
|
168 | # are layout-specific options that must be configured. |
|
|
169 | |
|
|
170 | ################################################################################ |
|
|
171 | # Authorization system |
|
|
172 | ################################################################################ |
|
|
173 | |
|
|
174 | # This lets you specify a minimum permission level needed to perform certain |
|
|
175 | # actions. In the current system, >=10 will allow a professor to perform the |
|
|
176 | # action, >=5 will allow a TA to, and >=0 will allow a student to perform an |
|
|
177 | # action (almost never what you want). |
|
|
178 | my $ta = 5; |
|
|
179 | my $professor = 10; |
|
|
180 | %permissionLevels = ( |
|
|
181 | become_student => $professor, |
|
|
182 | access_instructor_tools => $ta, |
|
|
183 | create_and_delete_problem_sets => $professor, |
|
|
184 | modify_problem_sets => $professor, |
|
|
185 | assign_problem_sets => $professor, |
|
|
186 | modify_student_data => $professor, |
|
|
187 | score_sets => $professor, |
|
|
188 | send_mail => $professor, |
|
|
189 | ); |
|
|
190 | |
|
|
191 | ################################################################################ |
|
|
192 | # Session options |
|
|
193 | ################################################################################ |
| 114 | |
194 | |
| 115 | # $sessionKeyTimeout defines seconds of inactivity before a key expires |
195 | # $sessionKeyTimeout defines seconds of inactivity before a key expires |
| 116 | $sessionKeyTimeout = 60*30; |
196 | $sessionKeyTimeout = 60*30; |
|
|
197 | |
|
|
198 | # $sessionKeyLength defines the length (in characters) of the session key |
|
|
199 | $sessionKeyLength = 40; |
|
|
200 | |
|
|
201 | # @sessionKeyChars lists the legal session key characters |
|
|
202 | @sessionKeyChars = ('A'..'Z', 'a'..'z', '0'..'9', '.', '^', '/', '!', '*'); |
| 117 | |
203 | |
| 118 | # Practice users are users who's names start with $practiceUser |
204 | # Practice users are users who's names start with $practiceUser |
| 119 | # (you can comment this out to remove practice user support) |
205 | # (you can comment this out to remove practice user support) |
| 120 | $practiceUserPrefix = "practice"; |
206 | $practiceUserPrefix = "practice"; |
| 121 | |
207 | |
| … | |
… | |
| 124 | # kindof a backdoor to the practice user system, since he doesn't have a |
210 | # kindof a backdoor to the practice user system, since he doesn't have a |
| 125 | # password. Come to think of it, why do we even have this?! |
211 | # password. Come to think of it, why do we even have this?! |
| 126 | #$debugPracticeUser = "practice666"; |
212 | #$debugPracticeUser = "practice666"; |
| 127 | |
213 | |
| 128 | ################################################################################ |
214 | ################################################################################ |
| 129 | # Database and session |
|
|
| 130 | ################################################################################ |
|
|
| 131 | |
|
|
| 132 | %dbInfo = ( |
|
|
| 133 | auth_type => "GDBM", |
|
|
| 134 | auth_passwd_file => "$courseDirs{auth_DATA}/$courseName\_password_DB", |
|
|
| 135 | auth_perm_file => "$courseDirs{auth_DATA}/$courseName\_permissions_DB", |
|
|
| 136 | auth_keys_file => "$courseDirs{auth_DATA}/keys", |
|
|
| 137 | wwdb_type => "GDBM", |
|
|
| 138 | wwdb_file => "$courseDirs{DATA}/$courseName\_webwork_DB", |
|
|
| 139 | cldb_type => "GDBM", |
|
|
| 140 | cldb_file => "$courseDirs{DATA}/$courseName\_classlist_DB", |
|
|
| 141 | psvn_digits => 5, |
|
|
| 142 | ); |
|
|
| 143 | |
|
|
| 144 | # This lets you specify a minimum permission level needed to perform |
|
|
| 145 | # certain actions. In the current system, >=10 will allow a professor |
|
|
| 146 | # to perform the action, >=5 will allow a TA to, and >=0 will allow a |
|
|
| 147 | # student to perform an action (almost never what you want). |
|
|
| 148 | %permissionLevels = ( |
|
|
| 149 | "become_student" => 10, |
|
|
| 150 | ); |
|
|
| 151 | |
|
|
| 152 | ################################################################################ |
|
|
| 153 | # PG translation options |
215 | # PG translation options |
| 154 | ################################################################################ |
216 | ################################################################################ |
| 155 | |
217 | |
| 156 | %pg = ( |
218 | %pg = ( |
|
|
219 | # options for various renderers |
|
|
220 | renderers => { |
|
|
221 | "WeBWorK::PG::Remote" => { |
|
|
222 | uri => "http://localhost:8089/RPC2" |
|
|
223 | } |
|
|
224 | }, |
|
|
225 | # currently selected renderer |
|
|
226 | renderer => "WeBWorK::PG::Local", |
|
|
227 | # directories used by PG |
|
|
228 | # options for various renderers |
|
|
229 | renderers => { |
|
|
230 | "WeBWorK::PG::Remote" => { |
|
|
231 | uri => "http://localhost:8089/RPC2" |
|
|
232 | } |
|
|
233 | }, |
|
|
234 | # currently selected renderer |
|
|
235 | renderer => "WeBWorK::PG::Local", |
|
|
236 | # directories used by PG |
|
|
237 | directories => { |
|
|
238 | # directories used only by PG |
|
|
239 | lib => "$pgRoot/lib", |
|
|
240 | macros => "$pgRoot/macros", |
|
|
241 | }, |
| 157 | options => { |
242 | options => { |
| 158 | # default translation options |
243 | # default translation options |
| 159 | displayMode => "images", |
244 | displayMode => "images", |
| 160 | showOldAnswers => 1, |
245 | showOldAnswers => 1, |
| 161 | showCorrectAnswers => 0, |
246 | showCorrectAnswers => 0, |
| 162 | showHints => 0, |
247 | showHints => 0, |
| 163 | showSolutions => 0, |
248 | showSolutions => 0, |
| 164 | catchWarnings => 1, |
249 | catchWarnings => 0, # there's a global warning catcher now |
| 165 | # default grader |
250 | # default grader |
| 166 | grader => "avg_problem_grader", |
251 | grader => "avg_problem_grader", |
|
|
252 | }, |
|
|
253 | # this will be customized in the course.conf file |
|
|
254 | specialPGEnvironmentVars => { |
|
|
255 | PRINT_FILE_NAMES_FOR => [ qw(gage apizer voloshin lr003k professor) ], |
|
|
256 | CAPA_Tools => "$courseDirs{macros}/CAPA_Tools/", |
|
|
257 | CAPA_MCTools => "$courseDirs{macros}/CAPA_MCTools/", |
|
|
258 | CAPA_Graphics_URL => "$courseDirs{html}/CAPA_Graphics/", |
|
|
259 | CAPA_GraphicsDirectory => "$courseDirs{html}CAPA_Graphics/", |
| 167 | }, |
260 | }, |
| 168 | # modules lists module names and the packages each contains |
261 | # modules lists module names and the packages each contains |
| 169 | modules => [ |
262 | modules => [ |
| 170 | [qw(DynaLoader)], |
263 | [qw(DynaLoader)], |
| 171 | [qw(Exporter)], |
264 | [qw(Exporter)], |