Skip to content

Commit

Permalink
Feat: 배포 실패 원인 찾기 #165
Browse files Browse the repository at this point in the history
  • Loading branch information
ujiiin committed Feb 19, 2024
1 parent 950d3b5 commit 94c1734
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions src/app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ dotenv.config();
import express, { Request, Response, NextFunction } from "express";
import cors from "cors";

// import db from "./models/index";
import db from "./models/index";
import { response } from "./config/response";
import { BaseError } from "./config/error";
import { status } from "./config/response.status";
Expand All @@ -23,14 +23,14 @@ import { healthRoute } from "./routes/health.route";
const app = express();

app.set("port", process.env.PORT || 3000);
// db.sequelize
// .sync({ force: false })
// .then(() => {
// console.log("데이터베이스 연결 성공");
// })
// .catch((err) => {
// console.error(err);
// });
db.sequelize
.sync({ force: false })
.then(() => {
console.log("데이터베이스 연결 성공");
})
.catch((err) => {
console.error(err);
});
app.use(cors());
app.use(express.static("public"));
app.use(express.json());
Expand Down

0 comments on commit 94c1734

Please sign in to comment.