Manage shared ARNavi VPS contours and application keys from infrastructure
This commit is contained in:
@@ -15,6 +15,9 @@ import { createDeviceGatewayIngest } from "./gateway-ingest.mjs";
|
||||
import { PostgresDeviceRepository } from "./postgres-repository.mjs";
|
||||
import { createTypedCommandRuntime } from "./typed-command-runtime.mjs";
|
||||
|
||||
import { B2Infrastructure } from "./b2/infrastructure.mjs";
|
||||
import { B2Secrets } from "./b2/secrets.mjs";
|
||||
|
||||
const config = await readConfig();
|
||||
const repository = new PostgresDeviceRepository({
|
||||
databaseUrl: config.databaseUrl,
|
||||
@@ -57,6 +60,9 @@ const server = createControlCoreApp({
|
||||
? () => edgeChannelSupervisor.status()
|
||||
: null,
|
||||
typedCommandRuntime,
|
||||
b2Infrastructure: process.env.DEVICE_B2_SECRET_ROOT ? new B2Infrastructure({
|
||||
pool: repository.pool, secrets: new B2Secrets(process.env.DEVICE_B2_SECRET_ROOT),
|
||||
}) : null,
|
||||
});
|
||||
|
||||
server.listen(config.port, config.host, () => {
|
||||
|
||||
Reference in New Issue
Block a user