Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F32200859
D4102.1765109846.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
555 B
Referenced Files
None
Subscribers
None
D4102.1765109846.diff
View Options
diff --git a/keyserver/src/utils/import-json.js b/keyserver/src/utils/import-json.js
--- a/keyserver/src/utils/import-json.js
+++ b/keyserver/src/utils/import-json.js
@@ -14,6 +14,14 @@
}
async function getJSON<T>(path: string): Promise<?T> {
+ const fromEnv = process.env[`COMM_JSONCONFIG_${path}`];
+ if (fromEnv) {
+ try {
+ return JSON.parse(fromEnv);
+ } catch (e) {
+ console.log(`failed to parse JSON from env for ${path}`, e);
+ }
+ }
try {
// $FlowFixMe
const importedJSON = await import(`../../${path}`);
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Dec 7, 12:17 PM (12 h, 1 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
5843769
Default Alt Text
D4102.1765109846.diff (555 B)
Attached To
Mode
D4102: [keyserver] Make importJSON check env variables
Attached
Detach File
Event Timeline
Log In to Comment