@checkstack/script-packages-backend 0.2.0 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +100 -0
- package/drizzle/0002_dry_sue_storm.sql +27 -0
- package/drizzle/meta/0002_snapshot.json +666 -0
- package/drizzle/meta/_journal.json +7 -0
- package/package.json +9 -6
- package/src/audit-delta.test.ts +127 -0
- package/src/audit-delta.ts +100 -0
- package/src/audit-parse.test.ts +128 -0
- package/src/audit-parse.ts +147 -0
- package/src/audit-runner.test.ts +230 -0
- package/src/audit-runner.ts +224 -0
- package/src/audit-scanner.test.ts +101 -0
- package/src/audit-scanner.ts +156 -0
- package/src/hooks.ts +14 -0
- package/src/index.ts +264 -3
- package/src/router.ts +49 -0
- package/src/sandbox-policy-router.test.ts +105 -0
- package/src/sandbox-policy.test.ts +119 -0
- package/src/sandbox-policy.ts +68 -0
- package/src/sandbox-startup-log.test.ts +128 -0
- package/src/sandbox-startup-log.ts +83 -0
- package/src/schema.ts +53 -1
- package/src/sdk-types-route.test.ts +121 -0
- package/src/sdk-types-route.ts +137 -0
- package/src/stores.ts +216 -1
- package/tsconfig.json +9 -0
|
@@ -0,0 +1,666 @@
|
|
|
1
|
+
{
|
|
2
|
+
"id": "c913f908-8b26-4449-b810-38216a495d81",
|
|
3
|
+
"prevId": "6c4865a1-d9ca-4b09-a63f-8119ddd39481",
|
|
4
|
+
"version": "7",
|
|
5
|
+
"dialect": "postgresql",
|
|
6
|
+
"tables": {
|
|
7
|
+
"public.script_package_audit_advisory": {
|
|
8
|
+
"name": "script_package_audit_advisory",
|
|
9
|
+
"schema": "",
|
|
10
|
+
"columns": {
|
|
11
|
+
"lockfile_hash": {
|
|
12
|
+
"name": "lockfile_hash",
|
|
13
|
+
"type": "text",
|
|
14
|
+
"primaryKey": false,
|
|
15
|
+
"notNull": true
|
|
16
|
+
},
|
|
17
|
+
"advisory_id": {
|
|
18
|
+
"name": "advisory_id",
|
|
19
|
+
"type": "text",
|
|
20
|
+
"primaryKey": false,
|
|
21
|
+
"notNull": true
|
|
22
|
+
},
|
|
23
|
+
"package_name": {
|
|
24
|
+
"name": "package_name",
|
|
25
|
+
"type": "text",
|
|
26
|
+
"primaryKey": false,
|
|
27
|
+
"notNull": true
|
|
28
|
+
},
|
|
29
|
+
"title": {
|
|
30
|
+
"name": "title",
|
|
31
|
+
"type": "text",
|
|
32
|
+
"primaryKey": false,
|
|
33
|
+
"notNull": true,
|
|
34
|
+
"default": "''"
|
|
35
|
+
},
|
|
36
|
+
"severity": {
|
|
37
|
+
"name": "severity",
|
|
38
|
+
"type": "text",
|
|
39
|
+
"primaryKey": false,
|
|
40
|
+
"notNull": true
|
|
41
|
+
},
|
|
42
|
+
"vulnerable_versions": {
|
|
43
|
+
"name": "vulnerable_versions",
|
|
44
|
+
"type": "text",
|
|
45
|
+
"primaryKey": false,
|
|
46
|
+
"notNull": true,
|
|
47
|
+
"default": "''"
|
|
48
|
+
},
|
|
49
|
+
"url": {
|
|
50
|
+
"name": "url",
|
|
51
|
+
"type": "text",
|
|
52
|
+
"primaryKey": false,
|
|
53
|
+
"notNull": false
|
|
54
|
+
},
|
|
55
|
+
"cvss_score": {
|
|
56
|
+
"name": "cvss_score",
|
|
57
|
+
"type": "double precision",
|
|
58
|
+
"primaryKey": false,
|
|
59
|
+
"notNull": false
|
|
60
|
+
},
|
|
61
|
+
"notified": {
|
|
62
|
+
"name": "notified",
|
|
63
|
+
"type": "boolean",
|
|
64
|
+
"primaryKey": false,
|
|
65
|
+
"notNull": true,
|
|
66
|
+
"default": false
|
|
67
|
+
},
|
|
68
|
+
"first_seen_at": {
|
|
69
|
+
"name": "first_seen_at",
|
|
70
|
+
"type": "timestamp",
|
|
71
|
+
"primaryKey": false,
|
|
72
|
+
"notNull": true,
|
|
73
|
+
"default": "now()"
|
|
74
|
+
}
|
|
75
|
+
},
|
|
76
|
+
"indexes": {
|
|
77
|
+
"script_package_audit_advisory_hash_idx": {
|
|
78
|
+
"name": "script_package_audit_advisory_hash_idx",
|
|
79
|
+
"columns": [
|
|
80
|
+
{
|
|
81
|
+
"expression": "lockfile_hash",
|
|
82
|
+
"isExpression": false,
|
|
83
|
+
"asc": true,
|
|
84
|
+
"nulls": "last"
|
|
85
|
+
}
|
|
86
|
+
],
|
|
87
|
+
"isUnique": false,
|
|
88
|
+
"concurrently": false,
|
|
89
|
+
"method": "btree",
|
|
90
|
+
"with": {}
|
|
91
|
+
}
|
|
92
|
+
},
|
|
93
|
+
"foreignKeys": {},
|
|
94
|
+
"compositePrimaryKeys": {
|
|
95
|
+
"script_package_audit_advisory_lockfile_hash_advisory_id_package_name_pk": {
|
|
96
|
+
"name": "script_package_audit_advisory_lockfile_hash_advisory_id_package_name_pk",
|
|
97
|
+
"columns": [
|
|
98
|
+
"lockfile_hash",
|
|
99
|
+
"advisory_id",
|
|
100
|
+
"package_name"
|
|
101
|
+
]
|
|
102
|
+
}
|
|
103
|
+
},
|
|
104
|
+
"uniqueConstraints": {},
|
|
105
|
+
"policies": {},
|
|
106
|
+
"checkConstraints": {},
|
|
107
|
+
"isRLSEnabled": false
|
|
108
|
+
},
|
|
109
|
+
"public.script_package_audit_state": {
|
|
110
|
+
"name": "script_package_audit_state",
|
|
111
|
+
"schema": "",
|
|
112
|
+
"columns": {
|
|
113
|
+
"id": {
|
|
114
|
+
"name": "id",
|
|
115
|
+
"type": "text",
|
|
116
|
+
"primaryKey": true,
|
|
117
|
+
"notNull": true,
|
|
118
|
+
"default": "'singleton'"
|
|
119
|
+
},
|
|
120
|
+
"last_run_at": {
|
|
121
|
+
"name": "last_run_at",
|
|
122
|
+
"type": "timestamp",
|
|
123
|
+
"primaryKey": false,
|
|
124
|
+
"notNull": false
|
|
125
|
+
},
|
|
126
|
+
"lockfile_hash": {
|
|
127
|
+
"name": "lockfile_hash",
|
|
128
|
+
"type": "text",
|
|
129
|
+
"primaryKey": false,
|
|
130
|
+
"notNull": false
|
|
131
|
+
},
|
|
132
|
+
"total": {
|
|
133
|
+
"name": "total",
|
|
134
|
+
"type": "integer",
|
|
135
|
+
"primaryKey": false,
|
|
136
|
+
"notNull": true,
|
|
137
|
+
"default": 0
|
|
138
|
+
},
|
|
139
|
+
"count_low": {
|
|
140
|
+
"name": "count_low",
|
|
141
|
+
"type": "integer",
|
|
142
|
+
"primaryKey": false,
|
|
143
|
+
"notNull": true,
|
|
144
|
+
"default": 0
|
|
145
|
+
},
|
|
146
|
+
"count_moderate": {
|
|
147
|
+
"name": "count_moderate",
|
|
148
|
+
"type": "integer",
|
|
149
|
+
"primaryKey": false,
|
|
150
|
+
"notNull": true,
|
|
151
|
+
"default": 0
|
|
152
|
+
},
|
|
153
|
+
"count_high": {
|
|
154
|
+
"name": "count_high",
|
|
155
|
+
"type": "integer",
|
|
156
|
+
"primaryKey": false,
|
|
157
|
+
"notNull": true,
|
|
158
|
+
"default": 0
|
|
159
|
+
},
|
|
160
|
+
"count_critical": {
|
|
161
|
+
"name": "count_critical",
|
|
162
|
+
"type": "integer",
|
|
163
|
+
"primaryKey": false,
|
|
164
|
+
"notNull": true,
|
|
165
|
+
"default": 0
|
|
166
|
+
},
|
|
167
|
+
"error_message": {
|
|
168
|
+
"name": "error_message",
|
|
169
|
+
"type": "text",
|
|
170
|
+
"primaryKey": false,
|
|
171
|
+
"notNull": false
|
|
172
|
+
}
|
|
173
|
+
},
|
|
174
|
+
"indexes": {},
|
|
175
|
+
"foreignKeys": {},
|
|
176
|
+
"compositePrimaryKeys": {},
|
|
177
|
+
"uniqueConstraints": {},
|
|
178
|
+
"policies": {},
|
|
179
|
+
"checkConstraints": {},
|
|
180
|
+
"isRLSEnabled": false
|
|
181
|
+
},
|
|
182
|
+
"public.script_package_blob": {
|
|
183
|
+
"name": "script_package_blob",
|
|
184
|
+
"schema": "",
|
|
185
|
+
"columns": {
|
|
186
|
+
"integrity": {
|
|
187
|
+
"name": "integrity",
|
|
188
|
+
"type": "text",
|
|
189
|
+
"primaryKey": true,
|
|
190
|
+
"notNull": true
|
|
191
|
+
},
|
|
192
|
+
"name": {
|
|
193
|
+
"name": "name",
|
|
194
|
+
"type": "text",
|
|
195
|
+
"primaryKey": false,
|
|
196
|
+
"notNull": true
|
|
197
|
+
},
|
|
198
|
+
"version": {
|
|
199
|
+
"name": "version",
|
|
200
|
+
"type": "text",
|
|
201
|
+
"primaryKey": false,
|
|
202
|
+
"notNull": true
|
|
203
|
+
},
|
|
204
|
+
"backend": {
|
|
205
|
+
"name": "backend",
|
|
206
|
+
"type": "text",
|
|
207
|
+
"primaryKey": false,
|
|
208
|
+
"notNull": true
|
|
209
|
+
},
|
|
210
|
+
"size_bytes": {
|
|
211
|
+
"name": "size_bytes",
|
|
212
|
+
"type": "bigint",
|
|
213
|
+
"primaryKey": false,
|
|
214
|
+
"notNull": true
|
|
215
|
+
},
|
|
216
|
+
"created_at": {
|
|
217
|
+
"name": "created_at",
|
|
218
|
+
"type": "timestamp",
|
|
219
|
+
"primaryKey": false,
|
|
220
|
+
"notNull": true,
|
|
221
|
+
"default": "now()"
|
|
222
|
+
}
|
|
223
|
+
},
|
|
224
|
+
"indexes": {
|
|
225
|
+
"script_package_blob_backend_idx": {
|
|
226
|
+
"name": "script_package_blob_backend_idx",
|
|
227
|
+
"columns": [
|
|
228
|
+
{
|
|
229
|
+
"expression": "backend",
|
|
230
|
+
"isExpression": false,
|
|
231
|
+
"asc": true,
|
|
232
|
+
"nulls": "last"
|
|
233
|
+
}
|
|
234
|
+
],
|
|
235
|
+
"isUnique": false,
|
|
236
|
+
"concurrently": false,
|
|
237
|
+
"method": "btree",
|
|
238
|
+
"with": {}
|
|
239
|
+
}
|
|
240
|
+
},
|
|
241
|
+
"foreignKeys": {},
|
|
242
|
+
"compositePrimaryKeys": {},
|
|
243
|
+
"uniqueConstraints": {},
|
|
244
|
+
"policies": {},
|
|
245
|
+
"checkConstraints": {},
|
|
246
|
+
"isRLSEnabled": false
|
|
247
|
+
},
|
|
248
|
+
"public.script_package_blob_gc_state": {
|
|
249
|
+
"name": "script_package_blob_gc_state",
|
|
250
|
+
"schema": "",
|
|
251
|
+
"columns": {
|
|
252
|
+
"id": {
|
|
253
|
+
"name": "id",
|
|
254
|
+
"type": "text",
|
|
255
|
+
"primaryKey": true,
|
|
256
|
+
"notNull": true,
|
|
257
|
+
"default": "'singleton'"
|
|
258
|
+
},
|
|
259
|
+
"last_run_at": {
|
|
260
|
+
"name": "last_run_at",
|
|
261
|
+
"type": "timestamp",
|
|
262
|
+
"primaryKey": false,
|
|
263
|
+
"notNull": false
|
|
264
|
+
},
|
|
265
|
+
"last_deleted": {
|
|
266
|
+
"name": "last_deleted",
|
|
267
|
+
"type": "integer",
|
|
268
|
+
"primaryKey": false,
|
|
269
|
+
"notNull": true,
|
|
270
|
+
"default": 0
|
|
271
|
+
},
|
|
272
|
+
"last_bytes_reclaimed": {
|
|
273
|
+
"name": "last_bytes_reclaimed",
|
|
274
|
+
"type": "bigint",
|
|
275
|
+
"primaryKey": false,
|
|
276
|
+
"notNull": true,
|
|
277
|
+
"default": 0
|
|
278
|
+
},
|
|
279
|
+
"total_bytes_reclaimed": {
|
|
280
|
+
"name": "total_bytes_reclaimed",
|
|
281
|
+
"type": "bigint",
|
|
282
|
+
"primaryKey": false,
|
|
283
|
+
"notNull": true,
|
|
284
|
+
"default": 0
|
|
285
|
+
}
|
|
286
|
+
},
|
|
287
|
+
"indexes": {},
|
|
288
|
+
"foreignKeys": {},
|
|
289
|
+
"compositePrimaryKeys": {},
|
|
290
|
+
"uniqueConstraints": {},
|
|
291
|
+
"policies": {},
|
|
292
|
+
"checkConstraints": {},
|
|
293
|
+
"isRLSEnabled": false
|
|
294
|
+
},
|
|
295
|
+
"public.script_package_install_state": {
|
|
296
|
+
"name": "script_package_install_state",
|
|
297
|
+
"schema": "",
|
|
298
|
+
"columns": {
|
|
299
|
+
"id": {
|
|
300
|
+
"name": "id",
|
|
301
|
+
"type": "text",
|
|
302
|
+
"primaryKey": true,
|
|
303
|
+
"notNull": true,
|
|
304
|
+
"default": "'singleton'"
|
|
305
|
+
},
|
|
306
|
+
"status": {
|
|
307
|
+
"name": "status",
|
|
308
|
+
"type": "text",
|
|
309
|
+
"primaryKey": false,
|
|
310
|
+
"notNull": true,
|
|
311
|
+
"default": "'idle'"
|
|
312
|
+
},
|
|
313
|
+
"lockfile_hash": {
|
|
314
|
+
"name": "lockfile_hash",
|
|
315
|
+
"type": "text",
|
|
316
|
+
"primaryKey": false,
|
|
317
|
+
"notNull": false
|
|
318
|
+
},
|
|
319
|
+
"manifest": {
|
|
320
|
+
"name": "manifest",
|
|
321
|
+
"type": "jsonb",
|
|
322
|
+
"primaryKey": false,
|
|
323
|
+
"notNull": true,
|
|
324
|
+
"default": "'[]'::jsonb"
|
|
325
|
+
},
|
|
326
|
+
"total_size_bytes": {
|
|
327
|
+
"name": "total_size_bytes",
|
|
328
|
+
"type": "bigint",
|
|
329
|
+
"primaryKey": false,
|
|
330
|
+
"notNull": true,
|
|
331
|
+
"default": 0
|
|
332
|
+
},
|
|
333
|
+
"last_installed_at": {
|
|
334
|
+
"name": "last_installed_at",
|
|
335
|
+
"type": "timestamp",
|
|
336
|
+
"primaryKey": false,
|
|
337
|
+
"notNull": false
|
|
338
|
+
},
|
|
339
|
+
"error_message": {
|
|
340
|
+
"name": "error_message",
|
|
341
|
+
"type": "text",
|
|
342
|
+
"primaryKey": false,
|
|
343
|
+
"notNull": false
|
|
344
|
+
}
|
|
345
|
+
},
|
|
346
|
+
"indexes": {},
|
|
347
|
+
"foreignKeys": {},
|
|
348
|
+
"compositePrimaryKeys": {},
|
|
349
|
+
"uniqueConstraints": {},
|
|
350
|
+
"policies": {},
|
|
351
|
+
"checkConstraints": {},
|
|
352
|
+
"isRLSEnabled": false
|
|
353
|
+
},
|
|
354
|
+
"public.script_package_lockfile_history": {
|
|
355
|
+
"name": "script_package_lockfile_history",
|
|
356
|
+
"schema": "",
|
|
357
|
+
"columns": {
|
|
358
|
+
"lockfile_hash": {
|
|
359
|
+
"name": "lockfile_hash",
|
|
360
|
+
"type": "text",
|
|
361
|
+
"primaryKey": true,
|
|
362
|
+
"notNull": true
|
|
363
|
+
},
|
|
364
|
+
"manifest": {
|
|
365
|
+
"name": "manifest",
|
|
366
|
+
"type": "jsonb",
|
|
367
|
+
"primaryKey": false,
|
|
368
|
+
"notNull": true,
|
|
369
|
+
"default": "'[]'::jsonb"
|
|
370
|
+
},
|
|
371
|
+
"recorded_at": {
|
|
372
|
+
"name": "recorded_at",
|
|
373
|
+
"type": "timestamp",
|
|
374
|
+
"primaryKey": false,
|
|
375
|
+
"notNull": true,
|
|
376
|
+
"default": "now()"
|
|
377
|
+
}
|
|
378
|
+
},
|
|
379
|
+
"indexes": {
|
|
380
|
+
"script_package_lockfile_history_recorded_idx": {
|
|
381
|
+
"name": "script_package_lockfile_history_recorded_idx",
|
|
382
|
+
"columns": [
|
|
383
|
+
{
|
|
384
|
+
"expression": "recorded_at",
|
|
385
|
+
"isExpression": false,
|
|
386
|
+
"asc": true,
|
|
387
|
+
"nulls": "last"
|
|
388
|
+
}
|
|
389
|
+
],
|
|
390
|
+
"isUnique": false,
|
|
391
|
+
"concurrently": false,
|
|
392
|
+
"method": "btree",
|
|
393
|
+
"with": {}
|
|
394
|
+
}
|
|
395
|
+
},
|
|
396
|
+
"foreignKeys": {},
|
|
397
|
+
"compositePrimaryKeys": {},
|
|
398
|
+
"uniqueConstraints": {},
|
|
399
|
+
"policies": {},
|
|
400
|
+
"checkConstraints": {},
|
|
401
|
+
"isRLSEnabled": false
|
|
402
|
+
},
|
|
403
|
+
"public.script_package_registry_config": {
|
|
404
|
+
"name": "script_package_registry_config",
|
|
405
|
+
"schema": "",
|
|
406
|
+
"columns": {
|
|
407
|
+
"id": {
|
|
408
|
+
"name": "id",
|
|
409
|
+
"type": "text",
|
|
410
|
+
"primaryKey": true,
|
|
411
|
+
"notNull": true,
|
|
412
|
+
"default": "'singleton'"
|
|
413
|
+
},
|
|
414
|
+
"registry_url": {
|
|
415
|
+
"name": "registry_url",
|
|
416
|
+
"type": "text",
|
|
417
|
+
"primaryKey": false,
|
|
418
|
+
"notNull": true,
|
|
419
|
+
"default": "'https://registry.npmjs.org/'"
|
|
420
|
+
},
|
|
421
|
+
"scoped_registries": {
|
|
422
|
+
"name": "scoped_registries",
|
|
423
|
+
"type": "jsonb",
|
|
424
|
+
"primaryKey": false,
|
|
425
|
+
"notNull": true,
|
|
426
|
+
"default": "'[]'::jsonb"
|
|
427
|
+
},
|
|
428
|
+
"auth_secret_ref": {
|
|
429
|
+
"name": "auth_secret_ref",
|
|
430
|
+
"type": "text",
|
|
431
|
+
"primaryKey": false,
|
|
432
|
+
"notNull": false
|
|
433
|
+
},
|
|
434
|
+
"ignore_scripts": {
|
|
435
|
+
"name": "ignore_scripts",
|
|
436
|
+
"type": "boolean",
|
|
437
|
+
"primaryKey": false,
|
|
438
|
+
"notNull": true,
|
|
439
|
+
"default": true
|
|
440
|
+
},
|
|
441
|
+
"updated_at": {
|
|
442
|
+
"name": "updated_at",
|
|
443
|
+
"type": "timestamp",
|
|
444
|
+
"primaryKey": false,
|
|
445
|
+
"notNull": true,
|
|
446
|
+
"default": "now()"
|
|
447
|
+
}
|
|
448
|
+
},
|
|
449
|
+
"indexes": {},
|
|
450
|
+
"foreignKeys": {},
|
|
451
|
+
"compositePrimaryKeys": {},
|
|
452
|
+
"uniqueConstraints": {},
|
|
453
|
+
"policies": {},
|
|
454
|
+
"checkConstraints": {},
|
|
455
|
+
"isRLSEnabled": false
|
|
456
|
+
},
|
|
457
|
+
"public.script_package_satellite_state": {
|
|
458
|
+
"name": "script_package_satellite_state",
|
|
459
|
+
"schema": "",
|
|
460
|
+
"columns": {
|
|
461
|
+
"satellite_id": {
|
|
462
|
+
"name": "satellite_id",
|
|
463
|
+
"type": "text",
|
|
464
|
+
"primaryKey": true,
|
|
465
|
+
"notNull": true
|
|
466
|
+
},
|
|
467
|
+
"lockfile_hash": {
|
|
468
|
+
"name": "lockfile_hash",
|
|
469
|
+
"type": "text",
|
|
470
|
+
"primaryKey": false,
|
|
471
|
+
"notNull": false
|
|
472
|
+
},
|
|
473
|
+
"status": {
|
|
474
|
+
"name": "status",
|
|
475
|
+
"type": "text",
|
|
476
|
+
"primaryKey": false,
|
|
477
|
+
"notNull": true,
|
|
478
|
+
"default": "'pending'"
|
|
479
|
+
},
|
|
480
|
+
"error_message": {
|
|
481
|
+
"name": "error_message",
|
|
482
|
+
"type": "text",
|
|
483
|
+
"primaryKey": false,
|
|
484
|
+
"notNull": false
|
|
485
|
+
},
|
|
486
|
+
"synced_at": {
|
|
487
|
+
"name": "synced_at",
|
|
488
|
+
"type": "timestamp",
|
|
489
|
+
"primaryKey": false,
|
|
490
|
+
"notNull": false
|
|
491
|
+
}
|
|
492
|
+
},
|
|
493
|
+
"indexes": {},
|
|
494
|
+
"foreignKeys": {},
|
|
495
|
+
"compositePrimaryKeys": {},
|
|
496
|
+
"uniqueConstraints": {},
|
|
497
|
+
"policies": {},
|
|
498
|
+
"checkConstraints": {},
|
|
499
|
+
"isRLSEnabled": false
|
|
500
|
+
},
|
|
501
|
+
"public.script_package_size_cap": {
|
|
502
|
+
"name": "script_package_size_cap",
|
|
503
|
+
"schema": "",
|
|
504
|
+
"columns": {
|
|
505
|
+
"id": {
|
|
506
|
+
"name": "id",
|
|
507
|
+
"type": "text",
|
|
508
|
+
"primaryKey": true,
|
|
509
|
+
"notNull": true,
|
|
510
|
+
"default": "'singleton'"
|
|
511
|
+
},
|
|
512
|
+
"warn_bytes": {
|
|
513
|
+
"name": "warn_bytes",
|
|
514
|
+
"type": "bigint",
|
|
515
|
+
"primaryKey": false,
|
|
516
|
+
"notNull": true,
|
|
517
|
+
"default": 157286400
|
|
518
|
+
},
|
|
519
|
+
"block_bytes": {
|
|
520
|
+
"name": "block_bytes",
|
|
521
|
+
"type": "bigint",
|
|
522
|
+
"primaryKey": false,
|
|
523
|
+
"notNull": true,
|
|
524
|
+
"default": 314572800
|
|
525
|
+
},
|
|
526
|
+
"updated_at": {
|
|
527
|
+
"name": "updated_at",
|
|
528
|
+
"type": "timestamp",
|
|
529
|
+
"primaryKey": false,
|
|
530
|
+
"notNull": true,
|
|
531
|
+
"default": "now()"
|
|
532
|
+
}
|
|
533
|
+
},
|
|
534
|
+
"indexes": {},
|
|
535
|
+
"foreignKeys": {},
|
|
536
|
+
"compositePrimaryKeys": {},
|
|
537
|
+
"uniqueConstraints": {},
|
|
538
|
+
"policies": {},
|
|
539
|
+
"checkConstraints": {},
|
|
540
|
+
"isRLSEnabled": false
|
|
541
|
+
},
|
|
542
|
+
"public.script_package_storage_config": {
|
|
543
|
+
"name": "script_package_storage_config",
|
|
544
|
+
"schema": "",
|
|
545
|
+
"columns": {
|
|
546
|
+
"id": {
|
|
547
|
+
"name": "id",
|
|
548
|
+
"type": "text",
|
|
549
|
+
"primaryKey": true,
|
|
550
|
+
"notNull": true,
|
|
551
|
+
"default": "'singleton'"
|
|
552
|
+
},
|
|
553
|
+
"active_backend": {
|
|
554
|
+
"name": "active_backend",
|
|
555
|
+
"type": "text",
|
|
556
|
+
"primaryKey": false,
|
|
557
|
+
"notNull": true,
|
|
558
|
+
"default": "'postgres'"
|
|
559
|
+
},
|
|
560
|
+
"migration_status": {
|
|
561
|
+
"name": "migration_status",
|
|
562
|
+
"type": "text",
|
|
563
|
+
"primaryKey": false,
|
|
564
|
+
"notNull": true,
|
|
565
|
+
"default": "'idle'"
|
|
566
|
+
},
|
|
567
|
+
"migration_target": {
|
|
568
|
+
"name": "migration_target",
|
|
569
|
+
"type": "text",
|
|
570
|
+
"primaryKey": false,
|
|
571
|
+
"notNull": false
|
|
572
|
+
},
|
|
573
|
+
"migrated_count": {
|
|
574
|
+
"name": "migrated_count",
|
|
575
|
+
"type": "integer",
|
|
576
|
+
"primaryKey": false,
|
|
577
|
+
"notNull": true,
|
|
578
|
+
"default": 0
|
|
579
|
+
},
|
|
580
|
+
"migration_error": {
|
|
581
|
+
"name": "migration_error",
|
|
582
|
+
"type": "text",
|
|
583
|
+
"primaryKey": false,
|
|
584
|
+
"notNull": false
|
|
585
|
+
},
|
|
586
|
+
"updated_at": {
|
|
587
|
+
"name": "updated_at",
|
|
588
|
+
"type": "timestamp",
|
|
589
|
+
"primaryKey": false,
|
|
590
|
+
"notNull": true,
|
|
591
|
+
"default": "now()"
|
|
592
|
+
}
|
|
593
|
+
},
|
|
594
|
+
"indexes": {},
|
|
595
|
+
"foreignKeys": {},
|
|
596
|
+
"compositePrimaryKeys": {},
|
|
597
|
+
"uniqueConstraints": {},
|
|
598
|
+
"policies": {},
|
|
599
|
+
"checkConstraints": {},
|
|
600
|
+
"isRLSEnabled": false
|
|
601
|
+
},
|
|
602
|
+
"public.script_packages": {
|
|
603
|
+
"name": "script_packages",
|
|
604
|
+
"schema": "",
|
|
605
|
+
"columns": {
|
|
606
|
+
"name": {
|
|
607
|
+
"name": "name",
|
|
608
|
+
"type": "text",
|
|
609
|
+
"primaryKey": true,
|
|
610
|
+
"notNull": true
|
|
611
|
+
},
|
|
612
|
+
"version": {
|
|
613
|
+
"name": "version",
|
|
614
|
+
"type": "text",
|
|
615
|
+
"primaryKey": false,
|
|
616
|
+
"notNull": true
|
|
617
|
+
},
|
|
618
|
+
"enabled": {
|
|
619
|
+
"name": "enabled",
|
|
620
|
+
"type": "boolean",
|
|
621
|
+
"primaryKey": false,
|
|
622
|
+
"notNull": true,
|
|
623
|
+
"default": true
|
|
624
|
+
},
|
|
625
|
+
"added_by": {
|
|
626
|
+
"name": "added_by",
|
|
627
|
+
"type": "text",
|
|
628
|
+
"primaryKey": false,
|
|
629
|
+
"notNull": false
|
|
630
|
+
},
|
|
631
|
+
"added_at": {
|
|
632
|
+
"name": "added_at",
|
|
633
|
+
"type": "timestamp",
|
|
634
|
+
"primaryKey": false,
|
|
635
|
+
"notNull": true,
|
|
636
|
+
"default": "now()"
|
|
637
|
+
},
|
|
638
|
+
"updated_at": {
|
|
639
|
+
"name": "updated_at",
|
|
640
|
+
"type": "timestamp",
|
|
641
|
+
"primaryKey": false,
|
|
642
|
+
"notNull": true,
|
|
643
|
+
"default": "now()"
|
|
644
|
+
}
|
|
645
|
+
},
|
|
646
|
+
"indexes": {},
|
|
647
|
+
"foreignKeys": {},
|
|
648
|
+
"compositePrimaryKeys": {},
|
|
649
|
+
"uniqueConstraints": {},
|
|
650
|
+
"policies": {},
|
|
651
|
+
"checkConstraints": {},
|
|
652
|
+
"isRLSEnabled": false
|
|
653
|
+
}
|
|
654
|
+
},
|
|
655
|
+
"enums": {},
|
|
656
|
+
"schemas": {},
|
|
657
|
+
"sequences": {},
|
|
658
|
+
"roles": {},
|
|
659
|
+
"policies": {},
|
|
660
|
+
"views": {},
|
|
661
|
+
"_meta": {
|
|
662
|
+
"columns": {},
|
|
663
|
+
"schemas": {},
|
|
664
|
+
"tables": {}
|
|
665
|
+
}
|
|
666
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@checkstack/script-packages-backend",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.0",
|
|
4
4
|
"license": "Elastic-2.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "src/index.ts",
|
|
@@ -14,12 +14,15 @@
|
|
|
14
14
|
"test": "bun test"
|
|
15
15
|
},
|
|
16
16
|
"dependencies": {
|
|
17
|
-
"@checkstack/
|
|
17
|
+
"@checkstack/auth-common": "0.7.2",
|
|
18
|
+
"@checkstack/backend-api": "0.20.0",
|
|
18
19
|
"@checkstack/common": "0.12.0",
|
|
19
|
-
"@checkstack/
|
|
20
|
-
"@checkstack/
|
|
21
|
-
"@checkstack/
|
|
22
|
-
"@
|
|
20
|
+
"@checkstack/notification-common": "1.2.1",
|
|
21
|
+
"@checkstack/sdk": "0.93.0",
|
|
22
|
+
"@checkstack/script-packages-common": "0.2.0",
|
|
23
|
+
"@checkstack/secrets-common": "0.1.0",
|
|
24
|
+
"@checkstack/secrets-backend": "0.1.1",
|
|
25
|
+
"@orpc/server": "^1.14.4",
|
|
23
26
|
"drizzle-orm": "^0.45.0",
|
|
24
27
|
"zod": "^4.0.0"
|
|
25
28
|
},
|