-
Notifications
You must be signed in to change notification settings - Fork 38
/
env_sample.json
285 lines (285 loc) · 15.8 KB
/
env_sample.json
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
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
{
"/* Required to set this with some value": "*/",
"/* Run the code here to generate https://raw.githubusercontent.com/openwisp/ansible-openwisp2/master/files/generate_django_secret_key.py": "*/",
"DJANGO_SECRET_KEY": "<Generate Secret Key>",
"/* Set the Timezone for the container (must rebuild if changed)": "*/",
"TZ": "America/Detroit",
"/* CSV List of hosts allowed, no spaces in between commas": "*/",
"ALLOWED_HOSTS": [
"127.0.0.1",
"localhost"
],
"/* The URL of a generic help or documentation site, to be used in the front end's drop-down menu": "*/",
"HELP_URL": "https://its.umich.edu/academics-research/teaching-learning/my-learning-analytics",
"/* Help for views. Specify URLs to overide defaults": "*/",
"/* URL_VIEW_RESOURCES_ACCESSED": "*/",
"/* URL_VIEW_ASSIGNMENT_PLANNING_V1": "*/",
"/* URL_VIEW_ASSIGNMENT_PLANNING": "*/",
"/* URL_VIEW_GRADE_DISTRIBUTION": "*/",
"/* ID for your Google Analytics, defaults to nothing/disabled": "*/",
"GA_ID": "",
"/* # The hex value to be used in the front end for the primary color of the palette and theme": "*/",
"PRIMARY_UI_COLOR": "#00274C",
"/* Configuration of CSP see https://django-csp.readthedocs.io/en/latest/configuration.html": "*/",
"/* To enable this at all you must set have the CSP key set": "*/",
"/* and REPORT_ONLY should be be false, otherwise it will just console Warn": "*/",
"CSP": {
"REPORT_ONLY": true,
"/* You should set your domain as the DEFAULT_SRC": "*/",
"DEFAULT_SRC": ["'self'","example.edu"],
"SCRIPT_SRC": ["'self'", "'unsafe-inline'", "'unsafe-eval'", "www.google-analytics.com"],
"IMG_SRC": ["'self'", "data:", "www.google-analytics.com"],
"OBJECT_SRC": [],
"MEDIA_SRC": [],
"/* If you're embedding in Canvas you may need to include instructure.com as FRAME_SRC": "*/",
"FRAME_SRC": [],
"FONT_SRC": ["'self'", "fonts.gstatic.com"],
"CONNECT_SRC": [],
"STYLE_SRC": ["'self'", "'unsafe-inline'"],
"BASE_URI": [],
"FRAME_ANCESTORS": [],
"FORM_ACTION": [],
"SANDBOX": [],
"REPORT_URI": [],
"MANIFEST_SRC": [],
"WORKER_SRC": [],
"PLUGIN_TYPES": [],
"REQUIRE_SRI_FOR": [],
"UPGRADE_INSECURE_REQUESTS": false,
"BLOCK_ALL_MIXED_CONTENT": false,
"INCLUDE_NONCE_IN": []
},
"/* default password length indicator incase of creating user from command line or LTI auto login": "*/",
"RANDOM_PASSWORD_DEFAULT_LENGTH": 32,
"/* Enable secure cookies, also set your trusted origin (example of instructure.com)": "*/",
"CSRF_COOKIE_SECURE": false,
"CSRF_TRUSTED_ORIGINS": ["instructure.com"],
"/* SameSite settings for Session and CSRF (defaults in settings.py should work)": "*/",
"SESSION_COOKIE_SAMESITE": null,
"CSRF_COOKIE_SAMESITE": null,
"/* Any logs that django outputs, turn these off for production": "*/",
"DJANGO_LOG_LEVEL": "DEBUG",
"DJANGO_DEBUG": true,
"DJANGO_TEMPLATE_DEBUG": true,
"/* Any other logs": "*/",
"ROOT_LOG_LEVEL": "INFO",
"/* How long to cache some URL's on the client (Defualt 3600 seconds)": "*/",
"/* CLIENT_CACHE_TIME=3600": "*/",
"/* MySQL Configuration": "*/",
"/* Mysql Django Engine name": "*/",
"MYSQL_ENGINE": "django.db.backends.mysql",
"/* Local database name": "*/",
"MYSQL_DATABASE": "student_dashboard",
"/* Local database user": "*/",
"MYSQL_USER": "student_dashboard_user",
"/* Local database password": "*/",
"MYSQL_PASSWORD": "student_dashboard_pw",
"/* Local database host": "*/",
"MYSQL_HOST": "student_dashboard_mysql",
"/* Local database port": "*/",
"MYSQL_PORT": 3306,
"/* Local database root password (optional)": "*/",
"MYSQL_ROOT_PASSWORD": "student_dashboard_root_pw",
"/* Default Canvas Data id increment for course id, user id, etc": "*/",
"CANVAS_DATA_ID_INCREMENT": 17700000000000000,
"/* Canvas Configuration": "*/",
"CANVAS_USER": "",
"/* strings for construct file download url": "*/",
"CANVAS_FILE_PREFIX": "https://example.instructure.com/files/",
"CANVAS_FILE_POSTFIX": "/download?download_frd=1",
"/* Paths to special login credentials (uses SAML)": "*/",
"GOOGLE_APPLICATION_CREDENTIALS": "/secrets/bq_cred.json",
"/* LTI Configuration": "*/",
"/* LTI is disabled by default": "*/",
"STUDENT_DASHBOARD_LTI": false,
"/* LTI 1.3 configuration":"*/",
"/* The first key of LTI_CONFIG is your Canvas domain name":"*/",
"LTI_CONFIG": {
"https://canvas.instructure.com": [
{
"/*The default set of variables for LTI validation":"*/",
"default": true,
"/*LTI Dev Key from Canvas":"*/",
"client_id": "17700000000000111",
"/*fill this out for your institution.":"*/",
"auth_login_url": "https://canvas.instructure.com/api/lti/authorize_redirect",
"/*fill this out for your institution.":"*/",
"auth_token_url": "https://canvas.instructure.com/login/oauth2/token",
"/*fill this out for your institution.":"*/",
"key_set_url": "https://canvas.instructure.com/api/lti/security/jwks",
"key_set":null,
"/*Tools private key for LTI validation":"*/",
"private_key_file": "/secrets/private.key",
"/*Tools public key for LTI validation":"*/",
"public_key_file": "/secrets/public.key",
"/*Tools installation id in platform":"*/",
"deployment_ids": ["27297:7db438071375c02373713c12c73869ff2f470b68"]
}
]
},
"/*Database caching using mysql cache for ltiv1p3":"*/",
"DB_CACHE_CONFIGS": {
"/*cache timeout":"*/",
"CACHE_TTL": 7200,
"/*Cache type":"*/",
"BACKEND": "django_mysql.cache.MySQLCache",
"/*cache tablename as stated in the 0018_adding_mysql_cache migration file":"*/",
"LOCATION": "django_myla_cache",
"CACHE_KEY_PREFIX": "myla",
"CACHE_OPTIONS": {"COMPRESS_MIN_LENGTH": 5000, "COMPRESS_LEVEL": 6}
},
"/* Set this to true to enable the backend login/logout URLs.": "*/",
"/* This is enabled by default if no external auth is enabled.": "*/",
"ENABLE_BACKEND_LOGIN": false,
"/* SAML Configuration": "*/",
"/* Set this to true if you plan to use SAML and then configure it": "*/",
"STUDENT_DASHBOARD_SAML": false,
"/* Where your local secrets are stored": "*/",
"SAML2_FILES_BASE": "/secrets/saml/",
"/* Location of remote metadata for SAML": "*/",
"SAML2_REMOTE_METADATA": "",
"/* Local location of pem file that goes with the metadata": "*/",
"SAML2_REMOTE_PEM_FILE": "",
"/* Base for Django to your accounts path": "*/",
"DJANGO_SAML2_URL_BASE": "http://localhost:5001/accounts/",
"/* ACS Redirect": "*/",
"DJANGO_ACS_DEFAULT_REDIRECT": "http://localhost:5001/",
"/* Login Redirect (If SAML enabled)": "*/",
"DJANGO_LOGIN_REDIRECT_URL": "http://localhost:5001/",
"/* Logout redirect (If SAML enabled)": "*/",
"/* This URL should be configured to the logout URL on SAML host": "*/",
"DJANGO_LOGOUT_REDIRECT_URL": "http://localhost:5001/",
"/* Optional token value to be used for token based authentication": "*/",
"DJANGO_WATCHMAN_TOKEN": "",
"/* A single default IDP to use if multiple are present in the SAML metadata (Get from Metadata)": "*/",
"DJANGO_SAML2_DEFAULT_IDP": "",
"/* CRON POD SETTINGS": "*/",
"/* ": "*/",
"/* All of these settings go together and need to be enabled for cron job": "*/",
"/* Uncomment all of these to run the cron": "*/",
"/* set this to be true on OpenShift pod for running cron job.": "*/",
"/* RUN_AT_TIMES and CRONTAB_SCHEDULE have no affect otherwise.": "*/",
"IS_CRON_POD": false,
"/* Time to run cron CSV separated times in HH:MM format.": "*/",
"/* An example is 02:00,04:00 to run at 2AM and 4AM": "*/",
"RUN_AT_TIMES": "",
"/* Time to run system cron": "*/",
"/* An example to match the above would be 0 2,4 * * *": "*/",
"/* This should run as frequently or more frequently than RUN_AT_TIMES": "*/",
"/* Use https://crontab.guru to validate your schedule": "*/",
"CRONTAB_SCHEDULE": "",
"/* How many values to pass to big query at a time in one run. This is configurable as I don't know what a max safe value is.": "*/",
"/* CRON_BQ_IN_LIMIT=20": "*/",
"/* Change this to set the max default weeks to allow. Default is currently 16. The issue is the end dates in Canvas currently are set 10 years out so it can't calculate the range.": "*/",
"/* MAX_DEFAULT_WEEKS=16": "*/",
"/* DEBUGGER SETTINGS": "*/",
"/* Enable Visual Studio Debugging Support (Default False)": "*/",
"/* You must also configure the following options": "*/",
"PTVSD_ENABLE": false,
"/* Port to run PTVSD on": "*/",
"PTVSD_REMOTE_PORT": 3000,
"/* Address to listen for PTVSD on": "*/",
"PTVSD_ADDRESS": "0.0.0.0",
"/* Whether or not to wait for ptvsd to attach before continuing (Default False)": "*/",
"PTVSD_WAIT_FOR_ATTACH": false,
"/* Control course view options globally": "*/",
"/* Current possible values are a CSV list of any/none/all of show_resources_accessed, show_assignment_planning, show_grade_distribution": "*/",
"/* By default this is empty and no views are disabled": "*/",
"/* options are as described in course_view_options table column names [\"show_assignment_planning\", \"show_grade_distribution\"]": "*/",
"VIEWS_DISABLED": "",
"/* Data Warehouse configuration": "*/",
"/* Uncomment these variables and fill them in if you're using cron to load": "*/",
"/* from a data warehouse. These are optional": "*/",
"/* Database engine driver": "*/",
"DATA_WAREHOUSE_ENGINE": "django.db.backends.postgresql",
"/* database name": "*/",
"DATA_WAREHOUSE_DATABASE": "",
"/* database user": "*/",
"DATA_WAREHOUSE_USER": "",
"/* database password": "*/",
"DATA_WAREHOUSE_PASSWORD": "",
"/* database host": "*/",
"DATA_WAREHOUSE_HOST": "",
"/* database port": "*/",
"/* DATA_WAREHOUSE_PORT=5432": "*/",
"/* Enable/Disable Unizin Date Warehouse specific features/data": "*/",
"DATA_WAREHOUSE_IS_UNIZIN": true,
"/* resource type for resource view add or remove per institution needs": "/*",
"RESOURCE_VALUES": {
"files": {"types": ["canvas"], "icon": "fas fa-file fa-lg"},
"videos": {"types": ["leccap", "mivideo"], "icon": "fas fa-video fa-lg"}
},
"/* Institute specific urls add or remove to your needs, will be used for Resources view": "*/",
"/*cron queries to pull the data from various caliper data sources replace if not relevant with your institution": "*/",
"RESOURCE_ACCESS_CONFIG": {
"canvas": {
"query": [
"SELECT 'canvas' AS resource_type, ",
"CAST(SUBSTR(JSON_EXTRACT_SCALAR(event, '$.object.id'), 35) AS STRING) AS resource_id, ",
"CAST(SUBSTR(JSON_EXTRACT_SCALAR(event, '$.membership.member.id'), 29) AS INT64) AS user_id, ",
"cast(null as string) AS user_login_name,",
"CAST(SUBSTR(JSON_EXTRACT_SCALAR(event, '$.group.id'), 31) AS INT64) AS course_id, ",
"COALESCE(",
"JSON_EXTRACT_SCALAR(event, '$.object.extensions[\\'com.instructure.canvas\\'].asset_name'), ",
"JSON_EXTRACT_SCALAR(event, '$.object.extensions[\\'com.instructure.canvas\\'].filename'), ",
"JSON_EXTRACT_SCALAR(event, '$.object.name'), ",
"'attachment'",
") as name, ",
"datetime(EVENT_TIME) as access_time ",
"FROM event_store.events ",
"where JSON_EXTRACT_SCALAR(event, '$.edApp.id') IN ",
"UNNEST(['http://m.canvas.umich.edu/' , 'http://umich.instructure.com/' ]) ",
"and type = 'NavigationEvent' ",
"and SUBSTR(JSON_EXTRACT_SCALAR(event, '$.object.id'), 24, 10) = 'attachment' ",
"and JSON_EXTRACT_SCALAR(event, '$.action') = 'NavigatedTo' ",
"and JSON_EXTRACT_SCALAR(event, '$.membership.member.id') is not null ",
"and SUBSTR(JSON_EXTRACT_SCALAR(event, '$.group.id'), 31) IN UNNEST(@course_ids) "
],
"app_display_name": "Canvas Files",
"canvas_course_id_format": "LONG",
"urls": {"prefix": "https://example.instructure.com/files/", "postfix": "/download?download_frd=1"}
},
"leccap": {
"query": [
"select 'leccap' AS resource_type, ",
"CAST(SUBSTR(JSON_EXTRACT_SCALAR(event, '$.object.id'), 48) AS STRING) AS resource_id, ",
"@canvas_data_id_increment + CAST(JSON_EXTRACT_SCALAR(event, '$.federatedSession.messageParameters.custom_canvas_user_id') AS INT64) AS user_id, ",
"cast(null as string) AS user_login_name,",
"@canvas_data_id_increment + CAST(JSON_EXTRACT_SCALAR(event, '$.federatedSession.messageParameters.custom_canvas_course_id') AS INT64) AS course_id, ",
"JSON_EXTRACT_SCALAR(event, '$.object.name') as name, ",
"datetime(EVENT_TIME) as access_time ",
"FROM event_store.events ",
"where JSON_EXTRACT_SCALAR(event, '$.edApp') = 'https://leccap.engin.umich.edu/#applicationName=Lecture+Capture' ",
"and type = 'MediaEvent' and JSON_EXTRACT_SCALAR(event, '$.action') = 'Started' ",
"and JSON_EXTRACT_SCALAR(event, '$.federatedSession.messageParameters.custom_canvas_course_id') is not null ",
"and JSON_EXTRACT_SCALAR(event, '$.federatedSession.messageParameters.custom_canvas_course_id') IN UNNEST(@course_ids_short) "
],
"app_display_name": "Lecture Capture",
"/* mention if the caliper event data is providing long or short canvas id and change the query to store long id as in this case": "*/",
"canvas_course_id_format": "SHORT",
"urls": {"prefix": "https://leccap.engin.umich.edu/leccap/viewer/r/", "postfix": ""}
},
"mivideo": {
"query": [
"SELECT 'mivideo' AS resource_type,",
"replace(JSON_EXTRACT_SCALAR(event, '$.object.id'), 'https://aakaf.mivideo.it.umich.edu/caliper/info/media/', '') AS resource_id,",
"cast(-1 as INT64) AS user_id,",
"replace(JSON_EXTRACT_SCALAR(event, '$.actor.id'), 'https://aakaf.mivideo.it.umich.edu/caliper/info/user/', '') AS user_login_name,",
"@canvas_data_id_increment + CAST(JSON_EXTRACT_SCALAR(event, '$.object.extensions.kaf:course_id') AS INT64) AS course_id,",
"JSON_EXTRACT_SCALAR(event, '$.object.name') AS name,",
"datetime(EVENT_TIME) AS access_time",
"FROM event_store.events WHERE",
"COALESCE(JSON_EXTRACT_SCALAR(event, '$.edApp.id'), JSON_EXTRACT_SCALAR(event, '$.edApp')) = 'https://aakaf.mivideo.it.umich.edu/caliper/info/app/KafEdApp'",
"AND TYPE = 'MediaEvent'",
"AND JSON_EXTRACT_SCALAR(event, '$.action') = 'Started'",
"AND JSON_EXTRACT_SCALAR(event, '$.object.extensions.kaf:course_id') IN UNNEST(@course_ids_short)"
],
"app_display_name": "MiVideo",
"/* mention if the caliper event data is providing long or short canvas id and change the query to store long id as in this case": "*/",
"canvas_course_id_format": "SHORT",
"urls": {"prefix": "https://aakaf.mivideo.it.umich.edu/caliper/info/media/", "postfix": ""}
}
},
"/* Disable/Enable courses_enabled api": "*/",
"COURSES_ENABLED" : false
}