macbook 에서 리눅스로 이동

This commit is contained in:
k3341095
2026-03-05 10:35:28 +09:00
commit ffd13c0fbb
83 changed files with 12262 additions and 0 deletions

24
backend/main.ts Normal file
View File

@@ -0,0 +1,24 @@
import { Elysia } from "elysia";
import cors from "@elysiajs/cors";
const app = new Elysia().use(
cors({
origin: ["http://127.0.0.1:3000", "http://localhost:3000"],
credentials: true,
}),
);
app.get("/", () => ({
service: "landing-backend",
status: "ok",
}));
app.get("/health", () => ({
status: "ok",
}));
const port = Number(process.env.PORT ?? 4000);
const hostname = process.env.HOST ?? "127.0.0.1";
const server = app.listen({ port, hostname });
console.log(`Backend listening on ${server.server!.url}`);