blob: cdd98fea7244be3e195b7b724cafb85dbb6eba8b (
plain)
1
2
3
4
5
6
7
8
|
// Copyright 2018-2020 the Deno authors. All rights reserved. MIT license.
const hostname = "0.0.0.0";
const port = +(Deno.args[0] ?? "8080");
const listener = Deno.listen({ hostname, port });
console.log(`Listening on ${hostname}:${port}`);
for await (const conn of listener) {
Deno.copy(conn, conn);
}
|