refacto(*): rename hostname to custom domain (#10100)

This commit is contained in:
Antoine Moreaux
2025-02-10 16:12:36 +01:00
committed by GitHub
parent 2a0f937899
commit f733307517
51 changed files with 285 additions and 4757 deletions

View File

@ -0,0 +1,25 @@
import { MigrationInterface, QueryRunner } from 'typeorm';
export class RenameHostnameToCustomDomain1739178177820
implements MigrationInterface
{
name = 'RenameHostnameToCustomDomain1739178177820';
public async up(queryRunner: QueryRunner): Promise<void> {
await queryRunner.query(
`ALTER TABLE "core"."workspace" RENAME COLUMN "hostname" TO "customDomain"`,
);
await queryRunner.query(
`ALTER TABLE "core"."workspace" RENAME CONSTRAINT "UQ_e6fa363bdaf45cbf8ce97bcebf0" TO "UQ_900f0a3eb789159c26c8bcb39cd"`,
);
}
public async down(queryRunner: QueryRunner): Promise<void> {
await queryRunner.query(
`ALTER TABLE "core"."workspace" RENAME CONSTRAINT "UQ_900f0a3eb789159c26c8bcb39cd" TO "UQ_e6fa363bdaf45cbf8ce97bcebf0"`,
);
await queryRunner.query(
`ALTER TABLE "core"."workspace" RENAME COLUMN "customDomain" TO "hostname"`,
);
}
}