@karmaniverous/jeeves-server 3.2.1 → 3.3.1

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/src/server.ts CHANGED
@@ -14,6 +14,7 @@ import Fastify from 'fastify';
14
14
  import { getConfig, initConfig, isConfigInitialized } from './config/index.js';
15
15
  import { apiRoute } from './routes/api/index.js';
16
16
  import { authRoute } from './routes/auth.js';
17
+ import { registerConfigRoute } from './routes/config.js';
17
18
  import { eventRoute } from './routes/event.js';
18
19
  import { healthRoute } from './routes/health.js';
19
20
  import { keysRoute } from './routes/keys.js';
@@ -44,6 +45,7 @@ async function start() {
44
45
  // Register routes
45
46
  await fastify.register(staticRoutes);
46
47
  await fastify.register(healthRoute);
48
+ registerConfigRoute(fastify);
47
49
  await fastify.register(authRoute);
48
50
  await fastify.register(keysRoute);
49
51
  await fastify.register(eventRoute);
@@ -83,8 +85,10 @@ async function start() {
83
85
  // Start queue processor
84
86
  startQueueProcessor();
85
87
 
86
- await fastify.listen({ port: config.port, host: '0.0.0.0' });
87
- console.log(`Jeeves server listening on port ${String(config.port)}`);
88
+ await fastify.listen({ port: config.port, host: config.host });
89
+ console.log(
90
+ `Jeeves server listening on ${config.host}:${String(config.port)}`,
91
+ );
88
92
  console.log(`Endpoints:`);
89
93
  console.log(` GET /browse/* - File browser SPA`);
90
94
  console.log(` GET /api/raw/* - Raw file serving`);