mirror of
https://github.com/Dokploy/dokploy.git
synced 2026-07-08 23:45:22 +02:00
feat(migration): add migration entry point and update start script
- Added a new entry point for migration in the esbuild configuration. - Updated the start script in package.json to run the migration before starting the server. - Removed the direct migration call from the server initialization process to streamline the workflow.
This commit is contained in:
@@ -15,7 +15,6 @@ import {
|
||||
} from "@dokploy/server";
|
||||
import { config } from "dotenv";
|
||||
import next from "next";
|
||||
import { migration } from "@/server/db/migration";
|
||||
import packageInfo from "../package.json";
|
||||
import { setupDockerContainerLogsWebSocketServer } from "./wss/docker-container-logs";
|
||||
import { setupDockerContainerTerminalWebSocketServer } from "./wss/docker-container-terminal";
|
||||
@@ -60,7 +59,6 @@ void app.prepare().then(async () => {
|
||||
if (process.env.NODE_ENV === "production" && !IS_CLOUD) {
|
||||
createDefaultMiddlewares();
|
||||
await initializeNetwork();
|
||||
await migration();
|
||||
await initCronJobs();
|
||||
await initSchedules();
|
||||
await initCancelDeployments();
|
||||
@@ -68,10 +66,6 @@ void app.prepare().then(async () => {
|
||||
await sendDokployRestartNotifications();
|
||||
}
|
||||
|
||||
if (IS_CLOUD && process.env.NODE_ENV === "production") {
|
||||
await migration();
|
||||
}
|
||||
|
||||
server.listen(PORT, HOST);
|
||||
console.log(`Server Started on: http://${HOST}:${PORT}`);
|
||||
await initEnterpriseBackupCronJobs();
|
||||
|
||||
Reference in New Issue
Block a user