From 137558065180666d068752f434656ab09625e9b7 Mon Sep 17 00:00:00 2001 From: Andras Bacsai Date: Tue, 29 Nov 2022 14:01:19 +0100 Subject: [PATCH] fix: migrations --- .../migration.sql | 32 ------------------- .../migration.sql | 0 2 files changed, 32 deletions(-) delete mode 100644 apps/api/prisma/migrations/20221129101300_keep_docker_images_locally_setting/migration.sql rename apps/api/prisma/migrations/{20221024204842_rollback_to_commit => 20221129130036_keep_local_docker_images}/migration.sql (100%) diff --git a/apps/api/prisma/migrations/20221129101300_keep_docker_images_locally_setting/migration.sql b/apps/api/prisma/migrations/20221129101300_keep_docker_images_locally_setting/migration.sql deleted file mode 100644 index 24181ee69..000000000 --- a/apps/api/prisma/migrations/20221129101300_keep_docker_images_locally_setting/migration.sql +++ /dev/null @@ -1,32 +0,0 @@ --- RedefineTables -PRAGMA foreign_keys=OFF; -CREATE TABLE "new_Setting" ( - "id" TEXT NOT NULL PRIMARY KEY, - "fqdn" TEXT, - "dualCerts" BOOLEAN NOT NULL DEFAULT false, - "minPort" INTEGER NOT NULL DEFAULT 9000, - "maxPort" INTEGER NOT NULL DEFAULT 9100, - "DNSServers" TEXT NOT NULL DEFAULT '1.1.1.1,8.8.8.8', - "ipv4" TEXT, - "ipv6" TEXT, - "arch" TEXT, - "concurrentBuilds" INTEGER NOT NULL DEFAULT 1, - "applicationStoragePathMigrationFinished" BOOLEAN NOT NULL DEFAULT false, - "numberOfDockerImagesKeptLocally" INTEGER NOT NULL DEFAULT 3, - "proxyDefaultRedirect" TEXT, - "doNotTrack" BOOLEAN NOT NULL DEFAULT false, - "sentryDSN" TEXT, - "isAPIDebuggingEnabled" BOOLEAN NOT NULL DEFAULT false, - "isRegistrationEnabled" BOOLEAN NOT NULL DEFAULT true, - "isAutoUpdateEnabled" BOOLEAN NOT NULL DEFAULT false, - "isDNSCheckEnabled" BOOLEAN NOT NULL DEFAULT true, - "isTraefikUsed" BOOLEAN NOT NULL DEFAULT true, - "createdAt" DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP, - "updatedAt" DATETIME NOT NULL -); -INSERT INTO "new_Setting" ("DNSServers", "applicationStoragePathMigrationFinished", "arch", "concurrentBuilds", "createdAt", "doNotTrack", "dualCerts", "fqdn", "id", "ipv4", "ipv6", "isAPIDebuggingEnabled", "isAutoUpdateEnabled", "isDNSCheckEnabled", "isRegistrationEnabled", "isTraefikUsed", "maxPort", "minPort", "proxyDefaultRedirect", "sentryDSN", "updatedAt") SELECT "DNSServers", "applicationStoragePathMigrationFinished", "arch", "concurrentBuilds", "createdAt", "doNotTrack", "dualCerts", "fqdn", "id", "ipv4", "ipv6", "isAPIDebuggingEnabled", "isAutoUpdateEnabled", "isDNSCheckEnabled", "isRegistrationEnabled", "isTraefikUsed", "maxPort", "minPort", "proxyDefaultRedirect", "sentryDSN", "updatedAt" FROM "Setting"; -DROP TABLE "Setting"; -ALTER TABLE "new_Setting" RENAME TO "Setting"; -CREATE UNIQUE INDEX "Setting_fqdn_key" ON "Setting"("fqdn"); -PRAGMA foreign_key_check; -PRAGMA foreign_keys=ON; diff --git a/apps/api/prisma/migrations/20221024204842_rollback_to_commit/migration.sql b/apps/api/prisma/migrations/20221129130036_keep_local_docker_images/migration.sql similarity index 100% rename from apps/api/prisma/migrations/20221024204842_rollback_to_commit/migration.sql rename to apps/api/prisma/migrations/20221129130036_keep_local_docker_images/migration.sql