/// import "std/dotenv/load.ts"; import { ConsoleHandler } from "std/log/handlers.ts"; import { LevelName, setup } from "std/log/mod.ts"; import { serveUi } from "./api/mod.ts"; import { runAllTasks } from "./app/mod.ts"; // runbot shouldn't be needed for webhooks? // import { runBot } from "./bot/mod.ts"; import "./bot/mod.ts"; const logLevel = Deno.env.get("LOG_LEVEL")?.toUpperCase() as LevelName ?? "INFO"; // setup logging setup({ handlers: { console: new ConsoleHandler(logLevel), }, loggers: { default: { level: logLevel, handlers: ["console"] }, }, }); // run parts of the app await Promise.all([ // runbot shouldn't be needed for webhooks? // runBot(), runAllTasks(), serveUi(), ]);