mirror of
https://github.com/eliasrenman/gardentron.git
synced 2026-03-16 20:46:07 +01:00
feat: added moisture checker
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
import { Server } from "socket.io";
|
||||
import { registerSockets } from "./sockets";
|
||||
import { registerCronjobs } from "./cron";
|
||||
|
||||
export async function startServer() {
|
||||
const port = 3000 || process.env.HTTP_PORT;
|
||||
const io = new Server({});
|
||||
|
||||
registerSockets(io);
|
||||
registerCronjobs();
|
||||
|
||||
io.listen(port);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user