forked from skyportal/skyportal
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconfig.yaml.defaults
420 lines (367 loc) · 12.3 KB
/
config.yaml.defaults
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
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
app:
title: SkyPortal
logos: # Logos to place in the top-left of the header/login page (zero or more)
- src: /static/images/skyportal_logo_dark.png
alt_text: Skyportal logo
login_message: |
For more information about the project, see
<a href="https://github.com/skyportal/skyportal">
https://github.com/skyportal/skyportal
</a>
secret_key: abc01234 # This secret key can be any random string of
# characters.
#
# You should re-generate this for your application
# using:
#
# base64.b64encode(os.urandom(50)).decode('ascii')
factory: skyportal.app_server.make_app
# this endpoint does not actually do anything -- it is just for testing
sedm_endpoint: http://pharos.caltech.edu/add_fritz
lt_host: 161.72.57.3
lt_port: 8080
lco_protocol: https
lco_host: observe.lco.global
lco_port: 443
ztf:
protocol: http
host: skipper.caltech.edu
port: 4000
# See https://stackoverflow.com/a/35604855 for syntax
# These are Javascript component routes
routes:
- path: "/"
component: HomePage
exact: True
- path: "/source/:id"
component: Source
- path: "/favorites"
component: FavoritesPage
- path: "/gcn_events/:dateobs"
component: GcnEventPage
- path: "/groups"
component: Groups
- path: "/group/:id"
component: Group
- path: "/profile"
component: Profile
- path: "/candidates"
component: CandidateList
- path: "/sources"
component: SourceList
- path: "/user/:id"
component: UserInfo
- path: "/upload_photometry/:id"
component: UploadPhotometry
- path: "/about"
component: About
- path: "/run/:id"
component: RunSummary
- path: "/manage_data/:id"
component: ManageDataForm
- path: "/filter/:fid"
component: Filter
- path: "/runs"
component: ObservingRunPage
- path: "/group_sources/:id"
component: GroupSources
- path: "/user_management"
component: UserManagement
- path: "/upload_spectrum/:id"
component: UploadSpectrum
- path: "/observability/:id"
component: Observability
- path: "/source/:id/finder"
component: FindingChart
- path: "/source/:id/periodogram"
component: Periodogram
- path: "/db_stats"
component: DBStats
- path: "/gcn_events"
component: GcnEvents
sidebar:
# See https://material-ui.com/components/material-icons/
- name: Dashboard
icon: Home
url: /
- name: Sources
icon: Storage
url: /sources
- name: Candidates
icon: Search
url: /candidates
- name: Favorites
icon: Star
url: /favorites
- name: Groups
icon: GroupWork
url: /groups
- name: Observing Runs
icon: LocalCafe
url: /runs
- name: GCN Events
icon: SettingsInputAntenna
url: /gcn_events
- name: About
icon: Info
url: /about
# See https://github.com/STRML/react-grid-layout for more on the grid package
homepage_grid:
# This section describes the grid on which Home Page widgets are laid out.
#
# The breakpoints describe screen sizes at which a different set of widget
# layouts should be used. Note that these breakpoints describe minimum width
# values, unlike the maximum width bounds used by Material UI breakpoints.
# For example, a breakpoint of "sm: 650" will match windows with width 650px
# or greater, until the next highest breakpoint is hit (probably a "md").
# This is different from Material UI, where a breakpoint of 650 would match
# window widths that are at most 650px.
#
# The cols describe the number of evenly spaced columns that make up the
# grid at a given breakpoint. For example, on extra-large screens (greater
# than ${breakpoints.xlg} pixels), the grid will use ${cols.xlg} columns of
# equal width to describe sizes of widgets based on the layouts provided.
#
# Optionally, you may provide a "row_height: {a rem value}" property in
# this section to change the height of a row on the grid. By default, this
# value is 9.375rem (150px for the default 16px = 1rem configuration).
breakpoints:
xlg: 1400
lg: 1150
md: 996
sm: 650
xs: 0
cols:
xlg: 16
lg: 12
md: 10
sm: 6
xs: 4
homepage_widgets:
# This section describes the specific widgets shown on the Home Page and how
# they are laid out by default on the grid of the page.
#
# The name of section should be the same as the widget's React component.
#
# The props property should be a set of properties to be passed on to the
# underlying React component for the widget. You may run into cases in which
# you must pass a more complex, dyamic property (perhaps fetched from the
# application redux store). Since you can not know that in the time of the
# configuration writing, such properties should be directly coded into the
# HomePage.jsx.template file (see the GroupList widget for an example)
#
# By default, any widget listed here is shown on the Home Page. However, you
# can give a widget the property "show: false" to turn off rendering of the
# widget.
#
# The resizable property determines whether the user is able to resize the
# widget after it has been rendered based on default layouts.
#
# Finally, the layouts property provides an array of default sizes/locations
# for each screen width breakpoint for the given widget. Layout arrays are
# given in the order [x, y, width, height], in units of grid columns/rows.
# For example, a layout array of [1, 2, 3, 4] will render a widget 3 grid
# columns in width, 4 grid rows in height, and have its upper-left corner at
# the column 1 (zero-indexed) and row 2. Note that each row is by default
# 150px in height. The row height can be altered in the homepage_grid
# section above (as well as other grid characteristics).
WeatherWidget:
resizeable: true
minW: 2
layouts:
xlg: [0, 3, 5, 2]
lg: [0, 3, 4, 1]
md: [0, 6, 5, 2]
sm: [0, 6, 6, 1]
xs: [0, 12, 4, 1]
SourceCounts:
props:
sinceDaysAgo: 7
resizeable: true
minW: 1.5
layouts:
xlg: [14, 0, 2, 1]
lg: [10, 0, 2, 1]
md: [8, 0, 2, 1]
sm: [4.5, 0, 1.5, 1]
xs: [0, 0, 4, 1]
RecentSources:
resizeable: true
minW: 2
layouts:
xlg: [0, 0, 5, 3]
lg: [0, 0, 4, 3]
md: [0, 3, 5, 3]
sm: [0, 3, 3, 3]
xs: [0, 4, 4, 3]
NewsFeed:
resizeable: true
minW: 2
layouts:
xlg: [10, 0, 4, 3]
lg: [7, 0, 3, 3]
md: [0, 0, 8, 3]
sm: [0, 0, 4.5, 3]
xs: [0, 1, 4, 3]
TopSources:
resizeable: true
minW: 2
layouts:
xlg: [5, 0, 5, 3]
lg: [4, 3, 3, 3]
md: [5, 3, 5, 3]
sm: [3, 3, 3, 3]
xs: [0, 7, 4, 3]
RecentGcnEvents:
resizeable: true
minW: 3
layouts:
xlg: [5, 3, 5, 2]
lg: [4, 3, 5, 2]
md: [5, 6, 5, 2]
sm: [0, 7, 6, 2]
xs: [0, 13, 4, 2]
GroupList:
props:
title: My Groups
resizeable: true
minW: 1.5
layouts:
xlg: [14, 1, 2, 2]
lg: [10, 1, 2, 2]
md: [8, 1, 2, 2]
sm: [4.5, 1, 1.5, 2]
xs: [0, 10, 4, 2]
database:
database: skyportal
host: localhost
port: 5432
user: skyportal
password:
server:
# From https://console.developers.google.com/
#
# - Create Client ID
# - Javascript origins: https://localhost:5000
# - Authorized redirect URLs: http://localhost:5000/complete/google-oauth2/
#
# You need to have Google+ API enabled; it takes a few minutes to activate.
host: localhost
port: 5000 # This is the public-facing port
# Whether the base URL is http or https
ssl: False
# According to the Tornado docs at
# https://www.tornadoweb.org/en/stable/guide/running.html#processes-and-ports:
#
# Due to the Python GIL (Global Interpreter Lock), it is necessary
# to run multiple Python processes to take full advantage of
# multi-CPU machines. Typically it is best to run one process per
# CPU.
processes: 4
# How many of the above processes should be dedicated to
# frontend only (i.e., no token authorized API requests)
dedicated_frontend_processes: 2
# Rate limit: number of requests per second (see https://www.nginx.com/blog/rate-limiting-nginx/)
rate_limit: 5
# Rate limit burst size (https://www.nginx.com/blog/rate-limiting-nginx/#bursts)
burst: 10
# In addition to the local network, specify any IP addresses that are to be
# exempt from API rate limiting
whitelisted_ips: []
# Specify IPs or address ranges (e.g., 130.211.0.0/22) that are associated
# with upstream load balancing.
# These trusted addresses are used to uncover the originating IP.
loadbalancer_ips: []
auth:
debug_login: True
google_oauth2_key:
google_oauth2_secret:
services:
dask: False
misc:
days_to_keep_unsaved_candidates: 7
minutes_to_keep_candidate_query_cache: 60
public_group_name: "Sitewide Group"
# Use a named cosmology from `astropy.cosmology.parameters.available` cosmologies
# or supply the arguments for an `astropy.cosmology.FLRW` cosmological instance.
# If {"flat": True} then use a subclass of the FLRW, called `FlatLambdaCMD`
# otherwise use `LambdaCDM`. See `utils.cosmology.py` for the way in which
# the user-supplied cosmology parameter set constructs the site-wide cosmology.
cosmology: Planck18_arXiv_v2
#cosmology: {H0: "65.0", Om0: 0.3, Ode0: 0.7, name: 'skyportal_user_cosmo'}
# The minimum signal-to-noise ratio/ n-sigma for lim mag cacluations to
# consider a photometry point as a detection
photometry_detection_threshold_nsigma: 3.0
# The airmass value below which to track hours for when plotting
# on an object's observability page
hours_below_airmass_threshold: 2.9
allow_nonadmins_delete_objs: False
weather:
# time in seconds to wait before fetching weather for a given telescope
refresh_time: 3600.0
# Get an API key at OpenWeatherMap https://openweathermap.org/price
# the free tier should be sufficent, as we cache the weather results
# for each telescope
openweather_api_key:
external_logging:
papertrail:
# get an account at https://papertrailapp.com
enabled: False
# change url to the correct subdomain for your account
# and change the port as well
url:
port:
# which log files, if any do you not want to send over to the 3rd party?
excluded_log_files: ["log/websocket_server.log"]
cron:
- interval: 60
script: jobs/count_unsaved_candidates.py
# - interval: 1440
# script: jobs/delete_unsaved_candidates.py
# limit: ["01:00", "02:00"]
twilio:
# Twilio Sendgrid API configs
# This needs to be set to a valid, Sendgrid-registered address in config.yaml
from_email:
# This needs to be obtained via Sendgrid setup on their site
sendgrid_api_key:
# Twilio SMS API configs
# These values must be valid ones from the Twitter API console
from_number:
sms_account_sid:
sms_auth_token:
smtp:
from_email: # This is both the email used to authenticate with smtplib and the sender address
password:
host: smtp.gmail.com # Default Gmail settings; modify as needed
port: 587 # Default Gmail settings; modify as needed
# This value needs to be either "sendgrid" or "smtp" (without quotes)
email_service:
invitations:
enabled: False # If debug_login=True above, invite tokens won't be used during auth
days_until_expiry: 3
email_subject: "You've been invited to collaborate on SkyPortal"
email_body_preamble: | # This can include HTML tags
Welcome to <b>SkyPortal</b>!
<br />
Some other text here.
notifications:
enabled: True
standard_stars:
ZTF: data/ztf_standards.csv
ESO: data/eso_standards.csv
# Parameters for the thumbnail classification function which labels
# images as grayscale or colored. See utils/thumbnail.py for the function.
image_grayscale_params:
thumb_size: 40
MSE_cutoff: 22
adjust_color_bias: True
slack:
microservice_port: 64100
expected_url_preamble: "https://hooks.slack.com/"
spectrum_types:
types:
- source
- host
- host_center
default: source