DenoDDeno
Powered by
BairdyB
Denoβ€’4y agoβ€’
3 replies
Bairdy

Deno process watcher. How?

This code when compile, runs a simple http server.
import { serve } from "https://deno.land/std@0.178.0/http/server.ts";
serve((_req) => new Response("Hello, world"));
import { serve } from "https://deno.land/std@0.178.0/http/server.ts";
serve((_req) => new Response("Hello, world"));

Can a separate Deno script be used to watch this process running and if it crashes for whatever reason, it restarts? In Linux you can configure unit file for it but I was wondering if Deno is currently able to watch a different process and restart it if it has exited.
Deno banner
DenoJoin
Chat about Deno, a modern runtime for JavaScript and TypeScript.
20,934Members
Resources
Recent Announcements

Similar Threads

Was this page helpful?

Similar Threads

Kill deno process tree
rauniorooRraunioroo / help
2y ago
How to troubleshoot runaway (100% CPU) deno process
rauniorooRraunioroo / help
2y ago