@contember/cli 2.1.0-alpha.30 → 2.1.0-alpha.35
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/development/run.cjs.map +1 -1
- package/dist/development/run.js.map +1 -1
- package/dist/development/src/commands/actions/ActionsGetEventCommand.cjs.map +1 -1
- package/dist/development/src/commands/actions/ActionsGetEventCommand.js.map +1 -1
- package/dist/development/src/commands/actions/ActionsListFailedEventsCommand.cjs.map +1 -1
- package/dist/development/src/commands/actions/ActionsListFailedEventsCommand.js.map +1 -1
- package/dist/development/src/commands/actions/ActionsListVariablesCommand.cjs.map +1 -1
- package/dist/development/src/commands/actions/ActionsListVariablesCommand.js.map +1 -1
- package/dist/development/src/commands/actions/ActionsRetryEventCommand.cjs.map +1 -1
- package/dist/development/src/commands/actions/ActionsRetryEventCommand.js.map +1 -1
- package/dist/development/src/commands/actions/ActionsSetVariablesCommand.cjs +7 -4
- package/dist/development/src/commands/actions/ActionsSetVariablesCommand.cjs.map +1 -1
- package/dist/development/src/commands/actions/ActionsSetVariablesCommand.js +7 -4
- package/dist/development/src/commands/actions/ActionsSetVariablesCommand.js.map +1 -1
- package/dist/development/src/commands/actions/ActionsStopEventCommand.cjs.map +1 -1
- package/dist/development/src/commands/actions/ActionsStopEventCommand.js.map +1 -1
- package/dist/development/src/commands/deploy/DeployCommand.cjs.map +1 -1
- package/dist/development/src/commands/deploy/DeployCommand.js.map +1 -1
- package/dist/development/src/commands/migrations/MigrationAmendCommand.cjs.map +1 -1
- package/dist/development/src/commands/migrations/MigrationAmendCommand.js.map +1 -1
- package/dist/development/src/commands/migrations/MigrationBlankCommand.cjs.map +1 -1
- package/dist/development/src/commands/migrations/MigrationBlankCommand.js.map +1 -1
- package/dist/development/src/commands/migrations/MigrationDescribeCommand.cjs.map +1 -1
- package/dist/development/src/commands/migrations/MigrationDescribeCommand.js.map +1 -1
- package/dist/development/src/commands/migrations/MigrationDiffCommand.cjs.map +1 -1
- package/dist/development/src/commands/migrations/MigrationDiffCommand.js.map +1 -1
- package/dist/development/src/commands/migrations/MigrationExecuteCommand.cjs.map +1 -1
- package/dist/development/src/commands/migrations/MigrationExecuteCommand.js.map +1 -1
- package/dist/development/src/commands/migrations/MigrationRebaseCommand.cjs.map +1 -1
- package/dist/development/src/commands/migrations/MigrationRebaseCommand.js.map +1 -1
- package/dist/development/src/commands/migrations/MigrationStatusCommand.cjs.map +1 -1
- package/dist/development/src/commands/migrations/MigrationStatusCommand.js.map +1 -1
- package/dist/development/src/commands/misc/VersionCommand.cjs.map +1 -1
- package/dist/development/src/commands/misc/VersionCommand.js.map +1 -1
- package/dist/development/src/commands/project/ProjectGenerateDocumentationCommand.cjs.map +1 -1
- package/dist/development/src/commands/project/ProjectGenerateDocumentationCommand.js.map +1 -1
- package/dist/development/src/commands/project/ProjectPrintSchemaCommand.cjs.map +1 -1
- package/dist/development/src/commands/project/ProjectPrintSchemaCommand.js.map +1 -1
- package/dist/development/src/commands/project/ProjectValidateCommand.cjs.map +1 -1
- package/dist/development/src/commands/project/ProjectValidateCommand.js.map +1 -1
- package/dist/development/src/commands/transfer/ExportCommand.cjs.map +1 -1
- package/dist/development/src/commands/transfer/ExportCommand.js.map +1 -1
- package/dist/development/src/commands/transfer/ImportCommand.cjs.map +1 -1
- package/dist/development/src/commands/transfer/ImportCommand.js.map +1 -1
- package/dist/development/src/commands/transfer/TransferCommand.cjs.map +1 -1
- package/dist/development/src/commands/transfer/TransferCommand.js.map +1 -1
- package/dist/development/src/commands/transfer/utils.cjs.map +1 -1
- package/dist/development/src/commands/transfer/utils.js.map +1 -1
- package/dist/development/src/commands/workspace/WorkspaceUpdateApiCommand.cjs +16 -14
- package/dist/development/src/commands/workspace/WorkspaceUpdateApiCommand.cjs.map +1 -1
- package/dist/development/src/commands/workspace/WorkspaceUpdateApiCommand.js +16 -14
- package/dist/development/src/commands/workspace/WorkspaceUpdateApiCommand.js.map +1 -1
- package/dist/development/src/consts.cjs.map +1 -1
- package/dist/development/src/dic.cjs +87 -3
- package/dist/development/src/dic.cjs.map +1 -1
- package/dist/development/src/dic.js +88 -4
- package/dist/development/src/dic.js.map +1 -1
- package/dist/development/src/lib/SystemClientProvider.cjs.map +1 -1
- package/dist/development/src/lib/SystemClientProvider.js.map +1 -1
- package/dist/development/src/lib/TenantClientProvider.cjs.map +1 -1
- package/dist/development/src/lib/TenantClientProvider.js.map +1 -1
- package/dist/development/src/lib/VersionChecker.cjs.map +1 -1
- package/dist/development/src/lib/VersionChecker.js.map +1 -1
- package/dist/development/src/lib/actions/ActionsClient.cjs.map +1 -1
- package/dist/development/src/lib/actions/ActionsClient.js.map +1 -1
- package/dist/development/src/lib/admin/AdminClient.cjs.map +1 -1
- package/dist/development/src/lib/admin/AdminClient.js.map +1 -1
- package/dist/development/src/lib/admin/AdminDeployer.cjs.map +1 -1
- package/dist/development/src/lib/admin/AdminDeployer.js.map +1 -1
- package/dist/development/src/lib/assertNever.cjs.map +1 -1
- package/dist/development/src/lib/assertNever.js.map +1 -1
- package/dist/development/src/lib/dsn.cjs.map +1 -1
- package/dist/development/src/lib/dsn.js.map +1 -1
- package/dist/development/src/lib/env.cjs.map +1 -1
- package/dist/development/src/lib/env.js.map +1 -1
- package/dist/development/src/lib/fs/DockerComposeManager.cjs.map +1 -1
- package/dist/development/src/lib/fs/DockerComposeManager.js.map +1 -1
- package/dist/development/src/lib/fs/FileSystem.cjs.map +1 -1
- package/dist/development/src/lib/fs/FileSystem.js.map +1 -1
- package/dist/development/src/lib/fs/YamlHandler.cjs.map +1 -1
- package/dist/development/src/lib/fs/YamlHandler.js.map +1 -1
- package/dist/development/src/lib/js/EsBuildBuilder.cjs.map +1 -1
- package/dist/development/src/lib/js/EsBuildBuilder.js.map +1 -1
- package/dist/development/src/lib/js/EvalExecutor.cjs.map +1 -1
- package/dist/development/src/lib/js/EvalExecutor.js.map +1 -1
- package/dist/development/src/lib/js/JsCodeRunner.cjs.map +1 -1
- package/dist/development/src/lib/js/JsCodeRunner.js.map +1 -1
- package/dist/development/src/lib/migrations/MigrationExecutionFacade.cjs.map +1 -1
- package/dist/development/src/lib/migrations/MigrationExecutionFacade.js.map +1 -1
- package/dist/development/src/lib/migrations/MigrationPrinter.cjs.map +1 -1
- package/dist/development/src/lib/migrations/MigrationPrinter.js.map +1 -1
- package/dist/development/src/lib/migrations/MigrationRebaseFacade.cjs.map +1 -1
- package/dist/development/src/lib/migrations/MigrationRebaseFacade.js.map +1 -1
- package/dist/development/src/lib/migrations/MigrationsStatusFacade.cjs.map +1 -1
- package/dist/development/src/lib/migrations/MigrationsStatusFacade.js.map +1 -1
- package/dist/development/src/lib/migrations/MigrationsValidator.cjs.map +1 -1
- package/dist/development/src/lib/migrations/MigrationsValidator.js.map +1 -1
- package/dist/development/src/lib/project/RemoteProject.cjs.map +1 -1
- package/dist/development/src/lib/project/RemoteProject.js.map +1 -1
- package/dist/development/src/lib/project/RemoteProjectProvider.cjs.map +1 -1
- package/dist/development/src/lib/project/RemoteProjectProvider.js.map +1 -1
- package/dist/development/src/lib/project/RemoteProjectResolver.cjs.map +1 -1
- package/dist/development/src/lib/project/RemoteProjectResolver.js.map +1 -1
- package/dist/development/src/lib/project/docs/components/EntityInfo.cjs +135 -177
- package/dist/development/src/lib/project/docs/components/EntityInfo.cjs.map +1 -1
- package/dist/development/src/lib/project/docs/components/EntityInfo.js +136 -178
- package/dist/development/src/lib/project/docs/components/EntityInfo.js.map +1 -1
- package/dist/development/src/lib/project/docs/components/EntityLink.cjs.map +1 -1
- package/dist/development/src/lib/project/docs/components/EntityLink.js.map +1 -1
- package/dist/development/src/lib/project/docs/components/FieldLink.cjs +5 -5
- package/dist/development/src/lib/project/docs/components/FieldLink.cjs.map +1 -1
- package/dist/development/src/lib/project/docs/components/FieldLink.js +5 -5
- package/dist/development/src/lib/project/docs/components/FieldLink.js.map +1 -1
- package/dist/development/src/lib/project/docs/components/FieldPermissions.cjs +8 -8
- package/dist/development/src/lib/project/docs/components/FieldPermissions.cjs.map +1 -1
- package/dist/development/src/lib/project/docs/components/FieldPermissions.js +8 -8
- package/dist/development/src/lib/project/docs/components/FieldPermissions.js.map +1 -1
- package/dist/development/src/lib/project/docs/components/FieldType.cjs +34 -36
- package/dist/development/src/lib/project/docs/components/FieldType.cjs.map +1 -1
- package/dist/development/src/lib/project/docs/components/FieldType.js +34 -36
- package/dist/development/src/lib/project/docs/components/FieldType.js.map +1 -1
- package/dist/development/src/lib/project/docs/components/OnDelete.cjs +22 -26
- package/dist/development/src/lib/project/docs/components/OnDelete.cjs.map +1 -1
- package/dist/development/src/lib/project/docs/components/OnDelete.js +22 -26
- package/dist/development/src/lib/project/docs/components/OnDelete.js.map +1 -1
- package/dist/development/src/lib/project/docs/components/ProjectInfo.cjs +16 -16
- package/dist/development/src/lib/project/docs/components/ProjectInfo.cjs.map +1 -1
- package/dist/development/src/lib/project/docs/components/ProjectInfo.js +16 -16
- package/dist/development/src/lib/project/docs/components/ProjectInfo.js.map +1 -1
- package/dist/development/src/lib/project/docs/components/SinglePermission.cjs.map +1 -1
- package/dist/development/src/lib/project/docs/components/SinglePermission.js.map +1 -1
- package/dist/development/src/lib/project/docs/components/utils.cjs.map +1 -1
- package/dist/development/src/lib/project/docs/components/utils.js.map +1 -1
- package/dist/development/src/lib/project/docs/projectDescribe.cjs.map +1 -1
- package/dist/development/src/lib/project/docs/projectDescribe.js.map +1 -1
- package/dist/development/src/lib/schema/SchemaLoader.cjs.map +1 -1
- package/dist/development/src/lib/schema/SchemaLoader.js.map +1 -1
- package/dist/development/src/lib/schema/SchemaValidationHelper.cjs.map +1 -1
- package/dist/development/src/lib/schema/SchemaValidationPrinter.cjs.map +1 -1
- package/dist/development/src/lib/schema/SchemaValidationPrinter.js.map +1 -1
- package/dist/development/src/lib/schema/collectReferences.cjs.map +1 -1
- package/dist/development/src/lib/schema/collectReferences.js.map +1 -1
- package/dist/development/src/lib/stream.cjs.map +1 -1
- package/dist/development/src/lib/stream.js.map +1 -1
- package/dist/development/src/lib/tenant/TenantClient.cjs.map +1 -1
- package/dist/development/src/lib/tenant/TenantClient.js.map +1 -1
- package/dist/development/src/lib/transfer/DataTransferClient.cjs +29 -27
- package/dist/development/src/lib/transfer/DataTransferClient.cjs.map +1 -1
- package/dist/development/src/lib/transfer/DataTransferClient.js +29 -27
- package/dist/development/src/lib/transfer/DataTransferClient.js.map +1 -1
- package/dist/development/src/lib/transfer/stdio.cjs.map +1 -1
- package/dist/development/src/lib/transfer/stdio.js.map +1 -1
- package/dist/development/src/lib/workspace/WorkspaceResolver.cjs +4 -4
- package/dist/development/src/lib/workspace/WorkspaceResolver.cjs.map +1 -1
- package/dist/development/src/lib/workspace/WorkspaceResolver.js +5 -5
- package/dist/development/src/lib/workspace/WorkspaceResolver.js.map +1 -1
- package/dist/production/run.cjs.map +1 -1
- package/dist/production/run.js +0 -0
- package/dist/production/run.js.map +1 -1
- package/dist/production/src/commands/actions/ActionsGetEventCommand.cjs.map +1 -1
- package/dist/production/src/commands/actions/ActionsGetEventCommand.js.map +1 -1
- package/dist/production/src/commands/actions/ActionsListFailedEventsCommand.cjs.map +1 -1
- package/dist/production/src/commands/actions/ActionsListFailedEventsCommand.js.map +1 -1
- package/dist/production/src/commands/actions/ActionsListVariablesCommand.cjs.map +1 -1
- package/dist/production/src/commands/actions/ActionsListVariablesCommand.js.map +1 -1
- package/dist/production/src/commands/actions/ActionsRetryEventCommand.cjs.map +1 -1
- package/dist/production/src/commands/actions/ActionsRetryEventCommand.js.map +1 -1
- package/dist/production/src/commands/actions/ActionsSetVariablesCommand.cjs +7 -4
- package/dist/production/src/commands/actions/ActionsSetVariablesCommand.cjs.map +1 -1
- package/dist/production/src/commands/actions/ActionsSetVariablesCommand.js +7 -4
- package/dist/production/src/commands/actions/ActionsSetVariablesCommand.js.map +1 -1
- package/dist/production/src/commands/actions/ActionsStopEventCommand.cjs.map +1 -1
- package/dist/production/src/commands/actions/ActionsStopEventCommand.js.map +1 -1
- package/dist/production/src/commands/deploy/DeployCommand.cjs.map +1 -1
- package/dist/production/src/commands/deploy/DeployCommand.js.map +1 -1
- package/dist/production/src/commands/migrations/MigrationAmendCommand.cjs.map +1 -1
- package/dist/production/src/commands/migrations/MigrationAmendCommand.js.map +1 -1
- package/dist/production/src/commands/migrations/MigrationBlankCommand.cjs.map +1 -1
- package/dist/production/src/commands/migrations/MigrationBlankCommand.js.map +1 -1
- package/dist/production/src/commands/migrations/MigrationDescribeCommand.cjs.map +1 -1
- package/dist/production/src/commands/migrations/MigrationDescribeCommand.js.map +1 -1
- package/dist/production/src/commands/migrations/MigrationDiffCommand.cjs.map +1 -1
- package/dist/production/src/commands/migrations/MigrationDiffCommand.js.map +1 -1
- package/dist/production/src/commands/migrations/MigrationExecuteCommand.cjs.map +1 -1
- package/dist/production/src/commands/migrations/MigrationExecuteCommand.js.map +1 -1
- package/dist/production/src/commands/migrations/MigrationRebaseCommand.cjs.map +1 -1
- package/dist/production/src/commands/migrations/MigrationRebaseCommand.js.map +1 -1
- package/dist/production/src/commands/migrations/MigrationStatusCommand.cjs.map +1 -1
- package/dist/production/src/commands/migrations/MigrationStatusCommand.js.map +1 -1
- package/dist/production/src/commands/misc/VersionCommand.cjs.map +1 -1
- package/dist/production/src/commands/misc/VersionCommand.js.map +1 -1
- package/dist/production/src/commands/project/ProjectGenerateDocumentationCommand.cjs.map +1 -1
- package/dist/production/src/commands/project/ProjectGenerateDocumentationCommand.js.map +1 -1
- package/dist/production/src/commands/project/ProjectPrintSchemaCommand.cjs.map +1 -1
- package/dist/production/src/commands/project/ProjectPrintSchemaCommand.js.map +1 -1
- package/dist/production/src/commands/project/ProjectValidateCommand.cjs.map +1 -1
- package/dist/production/src/commands/project/ProjectValidateCommand.js.map +1 -1
- package/dist/production/src/commands/transfer/ExportCommand.cjs.map +1 -1
- package/dist/production/src/commands/transfer/ExportCommand.js.map +1 -1
- package/dist/production/src/commands/transfer/ImportCommand.cjs.map +1 -1
- package/dist/production/src/commands/transfer/ImportCommand.js.map +1 -1
- package/dist/production/src/commands/transfer/TransferCommand.cjs.map +1 -1
- package/dist/production/src/commands/transfer/TransferCommand.js.map +1 -1
- package/dist/production/src/commands/transfer/utils.cjs.map +1 -1
- package/dist/production/src/commands/transfer/utils.js.map +1 -1
- package/dist/production/src/commands/workspace/WorkspaceUpdateApiCommand.cjs +16 -14
- package/dist/production/src/commands/workspace/WorkspaceUpdateApiCommand.cjs.map +1 -1
- package/dist/production/src/commands/workspace/WorkspaceUpdateApiCommand.js +16 -14
- package/dist/production/src/commands/workspace/WorkspaceUpdateApiCommand.js.map +1 -1
- package/dist/production/src/consts.cjs.map +1 -1
- package/dist/production/src/dic.cjs +87 -3
- package/dist/production/src/dic.cjs.map +1 -1
- package/dist/production/src/dic.js +88 -4
- package/dist/production/src/dic.js.map +1 -1
- package/dist/production/src/lib/SystemClientProvider.cjs.map +1 -1
- package/dist/production/src/lib/SystemClientProvider.js.map +1 -1
- package/dist/production/src/lib/TenantClientProvider.cjs.map +1 -1
- package/dist/production/src/lib/TenantClientProvider.js.map +1 -1
- package/dist/production/src/lib/VersionChecker.cjs.map +1 -1
- package/dist/production/src/lib/VersionChecker.js.map +1 -1
- package/dist/production/src/lib/actions/ActionsClient.cjs.map +1 -1
- package/dist/production/src/lib/actions/ActionsClient.js.map +1 -1
- package/dist/production/src/lib/admin/AdminClient.cjs.map +1 -1
- package/dist/production/src/lib/admin/AdminClient.js.map +1 -1
- package/dist/production/src/lib/admin/AdminDeployer.cjs.map +1 -1
- package/dist/production/src/lib/admin/AdminDeployer.js.map +1 -1
- package/dist/production/src/lib/assertNever.cjs.map +1 -1
- package/dist/production/src/lib/assertNever.js.map +1 -1
- package/dist/production/src/lib/dsn.cjs.map +1 -1
- package/dist/production/src/lib/dsn.js.map +1 -1
- package/dist/production/src/lib/env.cjs.map +1 -1
- package/dist/production/src/lib/env.js.map +1 -1
- package/dist/production/src/lib/fs/DockerComposeManager.cjs.map +1 -1
- package/dist/production/src/lib/fs/DockerComposeManager.js.map +1 -1
- package/dist/production/src/lib/fs/FileSystem.cjs.map +1 -1
- package/dist/production/src/lib/fs/FileSystem.js.map +1 -1
- package/dist/production/src/lib/fs/YamlHandler.cjs.map +1 -1
- package/dist/production/src/lib/fs/YamlHandler.js.map +1 -1
- package/dist/production/src/lib/js/EsBuildBuilder.cjs.map +1 -1
- package/dist/production/src/lib/js/EsBuildBuilder.js.map +1 -1
- package/dist/production/src/lib/js/EvalExecutor.cjs.map +1 -1
- package/dist/production/src/lib/js/EvalExecutor.js.map +1 -1
- package/dist/production/src/lib/js/JsCodeRunner.cjs.map +1 -1
- package/dist/production/src/lib/js/JsCodeRunner.js.map +1 -1
- package/dist/production/src/lib/migrations/MigrationExecutionFacade.cjs.map +1 -1
- package/dist/production/src/lib/migrations/MigrationExecutionFacade.js.map +1 -1
- package/dist/production/src/lib/migrations/MigrationPrinter.cjs.map +1 -1
- package/dist/production/src/lib/migrations/MigrationPrinter.js.map +1 -1
- package/dist/production/src/lib/migrations/MigrationRebaseFacade.cjs.map +1 -1
- package/dist/production/src/lib/migrations/MigrationRebaseFacade.js.map +1 -1
- package/dist/production/src/lib/migrations/MigrationsStatusFacade.cjs.map +1 -1
- package/dist/production/src/lib/migrations/MigrationsStatusFacade.js.map +1 -1
- package/dist/production/src/lib/migrations/MigrationsValidator.cjs.map +1 -1
- package/dist/production/src/lib/migrations/MigrationsValidator.js.map +1 -1
- package/dist/production/src/lib/project/RemoteProject.cjs.map +1 -1
- package/dist/production/src/lib/project/RemoteProject.js.map +1 -1
- package/dist/production/src/lib/project/RemoteProjectProvider.cjs.map +1 -1
- package/dist/production/src/lib/project/RemoteProjectProvider.js.map +1 -1
- package/dist/production/src/lib/project/RemoteProjectResolver.cjs.map +1 -1
- package/dist/production/src/lib/project/RemoteProjectResolver.js.map +1 -1
- package/dist/production/src/lib/project/docs/components/EntityInfo.cjs +39 -66
- package/dist/production/src/lib/project/docs/components/EntityInfo.cjs.map +1 -1
- package/dist/production/src/lib/project/docs/components/EntityInfo.js +40 -67
- package/dist/production/src/lib/project/docs/components/EntityInfo.js.map +1 -1
- package/dist/production/src/lib/project/docs/components/EntityLink.cjs.map +1 -1
- package/dist/production/src/lib/project/docs/components/EntityLink.js.map +1 -1
- package/dist/production/src/lib/project/docs/components/FieldLink.cjs.map +1 -1
- package/dist/production/src/lib/project/docs/components/FieldLink.js.map +1 -1
- package/dist/production/src/lib/project/docs/components/FieldPermissions.cjs.map +1 -1
- package/dist/production/src/lib/project/docs/components/FieldPermissions.js.map +1 -1
- package/dist/production/src/lib/project/docs/components/FieldType.cjs +3 -5
- package/dist/production/src/lib/project/docs/components/FieldType.cjs.map +1 -1
- package/dist/production/src/lib/project/docs/components/FieldType.js +3 -5
- package/dist/production/src/lib/project/docs/components/FieldType.js.map +1 -1
- package/dist/production/src/lib/project/docs/components/OnDelete.cjs +4 -8
- package/dist/production/src/lib/project/docs/components/OnDelete.cjs.map +1 -1
- package/dist/production/src/lib/project/docs/components/OnDelete.js +4 -8
- package/dist/production/src/lib/project/docs/components/OnDelete.js.map +1 -1
- package/dist/production/src/lib/project/docs/components/ProjectInfo.cjs.map +1 -1
- package/dist/production/src/lib/project/docs/components/ProjectInfo.js.map +1 -1
- package/dist/production/src/lib/project/docs/components/SinglePermission.cjs.map +1 -1
- package/dist/production/src/lib/project/docs/components/SinglePermission.js.map +1 -1
- package/dist/production/src/lib/project/docs/components/utils.cjs.map +1 -1
- package/dist/production/src/lib/project/docs/components/utils.js.map +1 -1
- package/dist/production/src/lib/project/docs/projectDescribe.cjs.map +1 -1
- package/dist/production/src/lib/project/docs/projectDescribe.js.map +1 -1
- package/dist/production/src/lib/schema/SchemaLoader.cjs.map +1 -1
- package/dist/production/src/lib/schema/SchemaLoader.js.map +1 -1
- package/dist/production/src/lib/schema/SchemaValidationHelper.cjs.map +1 -1
- package/dist/production/src/lib/schema/SchemaValidationPrinter.cjs.map +1 -1
- package/dist/production/src/lib/schema/SchemaValidationPrinter.js.map +1 -1
- package/dist/production/src/lib/schema/collectReferences.cjs.map +1 -1
- package/dist/production/src/lib/schema/collectReferences.js.map +1 -1
- package/dist/production/src/lib/stream.cjs.map +1 -1
- package/dist/production/src/lib/stream.js.map +1 -1
- package/dist/production/src/lib/tenant/TenantClient.cjs.map +1 -1
- package/dist/production/src/lib/tenant/TenantClient.js.map +1 -1
- package/dist/production/src/lib/transfer/DataTransferClient.cjs +29 -27
- package/dist/production/src/lib/transfer/DataTransferClient.cjs.map +1 -1
- package/dist/production/src/lib/transfer/DataTransferClient.js +29 -27
- package/dist/production/src/lib/transfer/DataTransferClient.js.map +1 -1
- package/dist/production/src/lib/transfer/stdio.cjs.map +1 -1
- package/dist/production/src/lib/transfer/stdio.js.map +1 -1
- package/dist/production/src/lib/workspace/WorkspaceResolver.cjs +4 -4
- package/dist/production/src/lib/workspace/WorkspaceResolver.cjs.map +1 -1
- package/dist/production/src/lib/workspace/WorkspaceResolver.js +5 -5
- package/dist/production/src/lib/workspace/WorkspaceResolver.js.map +1 -1
- package/dist/types/commands/actions/ActionsGetEventCommand.d.ts.map +1 -1
- package/dist/types/commands/actions/ActionsListFailedEventsCommand.d.ts.map +1 -1
- package/dist/types/commands/actions/ActionsListVariablesCommand.d.ts.map +1 -1
- package/dist/types/commands/actions/ActionsSetVariablesCommand.d.ts.map +1 -1
- package/dist/types/commands/deploy/DeployCommand.d.ts.map +1 -1
- package/dist/types/commands/migrations/MigrationAmendCommand.d.ts.map +1 -1
- package/dist/types/commands/migrations/MigrationBlankCommand.d.ts.map +1 -1
- package/dist/types/commands/migrations/MigrationDescribeCommand.d.ts.map +1 -1
- package/dist/types/commands/migrations/MigrationDiffCommand.d.ts.map +1 -1
- package/dist/types/commands/migrations/MigrationExecuteCommand.d.ts.map +1 -1
- package/dist/types/commands/migrations/MigrationRebaseCommand.d.ts.map +1 -1
- package/dist/types/commands/migrations/MigrationStatusCommand.d.ts.map +1 -1
- package/dist/types/commands/project/ProjectGenerateDocumentationCommand.d.ts.map +1 -1
- package/dist/types/commands/project/ProjectPrintSchemaCommand.d.ts.map +1 -1
- package/dist/types/commands/transfer/TransferCommand.d.ts.map +1 -1
- package/dist/types/commands/transfer/utils.d.ts.map +1 -1
- package/dist/types/commands/workspace/WorkspaceUpdateApiCommand.d.ts.map +1 -1
- package/dist/types/dic.d.ts.map +1 -1
- package/dist/types/lib/VersionChecker.d.ts.map +1 -1
- package/dist/types/lib/actions/ActionsClient.d.ts.map +1 -1
- package/dist/types/lib/admin/AdminClient.d.ts.map +1 -1
- package/dist/types/lib/admin/AdminDeployer.d.ts.map +1 -1
- package/dist/types/lib/fs/DockerComposeManager.d.ts.map +1 -1
- package/dist/types/lib/migrations/MigrationPrinter.d.ts.map +1 -1
- package/dist/types/lib/migrations/MigrationsStatusFacade.d.ts.map +1 -1
- package/dist/types/lib/project/docs/components/EntityInfo.d.ts.map +1 -1
- package/dist/types/lib/project/docs/components/FieldLink.d.ts.map +1 -1
- package/dist/types/lib/project/docs/components/FieldPermissions.d.ts.map +1 -1
- package/dist/types/lib/project/docs/components/FieldType.d.ts.map +1 -1
- package/dist/types/lib/project/docs/components/OnDelete.d.ts.map +1 -1
- package/dist/types/lib/project/docs/components/ProjectInfo.d.ts.map +1 -1
- package/dist/types/lib/project/docs/projectDescribe.d.ts.map +1 -1
- package/dist/types/lib/schema/SchemaValidationPrinter.d.ts.map +1 -1
- package/dist/types/lib/stream.d.ts.map +1 -1
- package/dist/types/lib/tenant/TenantClient.d.ts.map +1 -1
- package/dist/types/lib/transfer/DataTransferClient.d.ts.map +1 -1
- package/package.json +39 -35
- package/src/commands/actions/ActionsGetEventCommand.ts +0 -1
- package/src/commands/actions/ActionsListFailedEventsCommand.ts +1 -3
- package/src/commands/actions/ActionsListVariablesCommand.ts +1 -2
- package/src/commands/actions/ActionsSetVariablesCommand.ts +13 -7
- package/src/commands/deploy/DeployCommand.ts +0 -3
- package/src/commands/migrations/MigrationAmendCommand.ts +2 -2
- package/src/commands/migrations/MigrationBlankCommand.ts +1 -3
- package/src/commands/migrations/MigrationDescribeCommand.ts +0 -1
- package/src/commands/migrations/MigrationDiffCommand.ts +0 -2
- package/src/commands/migrations/MigrationExecuteCommand.ts +1 -2
- package/src/commands/migrations/MigrationRebaseCommand.ts +0 -2
- package/src/commands/migrations/MigrationStatusCommand.ts +7 -12
- package/src/commands/project/ProjectGenerateDocumentationCommand.ts +1 -2
- package/src/commands/project/ProjectPrintSchemaCommand.ts +1 -3
- package/src/commands/transfer/ImportCommand.ts +1 -2
- package/src/commands/transfer/TransferCommand.ts +2 -3
- package/src/commands/transfer/utils.ts +0 -1
- package/src/commands/workspace/WorkspaceUpdateApiCommand.ts +16 -14
- package/src/dic.ts +150 -116
- package/src/lib/VersionChecker.ts +0 -2
- package/src/lib/actions/ActionsClient.ts +0 -1
- package/src/lib/admin/AdminClient.ts +2 -2
- package/src/lib/admin/AdminDeployer.ts +0 -1
- package/src/lib/fs/DockerComposeManager.ts +0 -3
- package/src/lib/migrations/MigrationPrinter.ts +0 -2
- package/src/lib/migrations/MigrationsStatusFacade.ts +0 -1
- package/src/lib/project/RemoteProjectResolver.ts +2 -2
- package/src/lib/project/docs/components/EntityInfo.tsx +36 -31
- package/src/lib/project/docs/components/FieldLink.tsx +5 -1
- package/src/lib/project/docs/components/FieldPermissions.tsx +8 -6
- package/src/lib/project/docs/components/FieldType.tsx +31 -30
- package/src/lib/project/docs/components/OnDelete.tsx +15 -13
- package/src/lib/project/docs/components/ProjectInfo.tsx +1 -4
- package/src/lib/project/docs/components/SinglePermission.tsx +0 -1
- package/src/lib/project/docs/components/utils.ts +0 -1
- package/src/lib/project/docs/projectDescribe.tsx +0 -2
- package/src/lib/project/docs/resources/style.css +2 -3
- package/src/lib/schema/SchemaLoader.ts +1 -1
- package/src/lib/schema/SchemaValidationPrinter.ts +0 -1
- package/src/lib/stream.ts +7 -8
- package/src/lib/tenant/TenantClient.ts +0 -1
- package/src/lib/transfer/DataTransferClient.ts +32 -32
- package/src/lib/transfer/stdio.ts +0 -1
- package/src/lib/workspace/WorkspaceResolver.ts +5 -5
- package/src/run.ts +2 -5
- package/dist/types/tsconfig.tsbuildinfo +0 -1
- package/postcss.config.js +0 -6
- package/src/.eslintrc.cjs +0 -5
- package/src/lib/project/docs/.eslintrc.cjs +0 -5
- package/tailwind.config.js +0 -7
|
@@ -18,7 +18,6 @@ export class MigrationRebaseCommand extends Command<Args, Options> {
|
|
|
18
18
|
super()
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
-
|
|
22
21
|
protected configure(configuration: CommandConfiguration<Args, Options>): void {
|
|
23
22
|
configuration.description('Rebase migrations on filesystem and in local instance')
|
|
24
23
|
configuration.argument('migration').variadic()
|
|
@@ -29,7 +28,6 @@ export class MigrationRebaseCommand extends Command<Args, Options> {
|
|
|
29
28
|
}
|
|
30
29
|
|
|
31
30
|
protected async execute(input: Input<Args, Options>): Promise<void> {
|
|
32
|
-
|
|
33
31
|
const migrationNames = input.getArgument('migration')
|
|
34
32
|
|
|
35
33
|
const migrations: Migration[] = []
|
|
@@ -5,8 +5,7 @@ import { MigrationsStatusFacade } from '../../lib/migrations/MigrationsStatusFac
|
|
|
5
5
|
import { MigrationPrinter } from '../../lib/migrations/MigrationPrinter'
|
|
6
6
|
import { SystemClientProvider } from '../../lib/SystemClientProvider'
|
|
7
7
|
|
|
8
|
-
type Args = {
|
|
9
|
-
}
|
|
8
|
+
type Args = {}
|
|
10
9
|
|
|
11
10
|
type Options = {
|
|
12
11
|
['only-to-execute']?: true
|
|
@@ -41,7 +40,6 @@ export class MigrationStatusCommand extends Command<Args, Options> {
|
|
|
41
40
|
}
|
|
42
41
|
|
|
43
42
|
protected async execute(input: Input<Args, Options>): Promise<number> {
|
|
44
|
-
|
|
45
43
|
const onlyErrors = input.getOption('only-errors')
|
|
46
44
|
const onlyToExecute = input.getOption('only-to-execute')
|
|
47
45
|
const restoreMissing = input.getOption('restore-missing')
|
|
@@ -68,15 +66,12 @@ export class MigrationStatusCommand extends Command<Args, Options> {
|
|
|
68
66
|
status = await this.migrationsStatusFacade.resolveMigrationsStatus({})
|
|
69
67
|
}
|
|
70
68
|
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
...(onlyToExecute ? status.migrationsToExecute : []),
|
|
78
|
-
])
|
|
79
|
-
: status.allMigrations
|
|
69
|
+
const filtered = onlyErrors || onlyToExecute
|
|
70
|
+
? sortMigrations([
|
|
71
|
+
...(onlyErrors ? status.errorMigrations : []),
|
|
72
|
+
...(onlyToExecute ? status.migrationsToExecute : []),
|
|
73
|
+
])
|
|
74
|
+
: status.allMigrations
|
|
80
75
|
|
|
81
76
|
console.log(this.migrationPrinter.printStatusTable(filtered))
|
|
82
77
|
|
|
@@ -6,8 +6,7 @@ import { SchemaLoader } from '../../lib/schema/SchemaLoader'
|
|
|
6
6
|
import { validateSchemaAndPrintErrors } from '../../lib/schema/SchemaValidationHelper'
|
|
7
7
|
import { SchemaVersionBuilder } from '@contember/migrations-client'
|
|
8
8
|
|
|
9
|
-
type Args = {
|
|
10
|
-
}
|
|
9
|
+
type Args = {}
|
|
11
10
|
|
|
12
11
|
type Options = {
|
|
13
12
|
source?: 'migrations' | 'definition'
|
|
@@ -14,8 +14,7 @@ import { SchemaLoader } from '../../lib/schema/SchemaLoader'
|
|
|
14
14
|
import { SchemaVersionBuilder } from '@contember/migrations-client'
|
|
15
15
|
import { validateSchemaAndPrintErrors } from '../../lib/schema/SchemaValidationHelper'
|
|
16
16
|
|
|
17
|
-
type Args = {
|
|
18
|
-
}
|
|
17
|
+
type Args = {}
|
|
19
18
|
|
|
20
19
|
type Options = {
|
|
21
20
|
role?: string[]
|
|
@@ -51,7 +50,6 @@ export class ProjectPrintSchemaCommand extends Command<Args, Options> {
|
|
|
51
50
|
protected async execute(input: Input<Args, Options>): Promise<number> {
|
|
52
51
|
const format = input.getOption('format') || 'graphql'
|
|
53
52
|
|
|
54
|
-
|
|
55
53
|
const schema = input.getOption('source') === 'migrations'
|
|
56
54
|
? await this.schemaVersionBuilder.buildSchema()
|
|
57
55
|
: await this.schemaLoader.loadSchema()
|
|
@@ -51,7 +51,7 @@ export class ImportCommand extends Command<Args, Options> {
|
|
|
51
51
|
}
|
|
52
52
|
const file = input.getArgument('file')
|
|
53
53
|
const baseInputStream = createReadStream(file)
|
|
54
|
-
const stream =
|
|
54
|
+
const stream = file.endsWith('.gz') ? baseInputStream.pipe(createGunzip()) : baseInputStream
|
|
55
55
|
stream.on('error', (err: any) => {
|
|
56
56
|
console.error('Error in import stream:', err)
|
|
57
57
|
})
|
|
@@ -74,4 +74,3 @@ export class ImportCommand extends Command<Args, Options> {
|
|
|
74
74
|
}
|
|
75
75
|
}
|
|
76
76
|
}
|
|
77
|
-
|
|
@@ -50,7 +50,6 @@ export class TransferCommand extends Command<Args, Options> {
|
|
|
50
50
|
throw `Target project not defined`
|
|
51
51
|
}
|
|
52
52
|
|
|
53
|
-
|
|
54
53
|
console.log('')
|
|
55
54
|
console.log('Transferring data between projects:')
|
|
56
55
|
console.log('')
|
|
@@ -68,12 +67,12 @@ export class TransferCommand extends Command<Args, Options> {
|
|
|
68
67
|
|
|
69
68
|
const includeSystem = input.getOption('include-system') === true
|
|
70
69
|
const gzipTransfer = !input.getOption('no-gzip-transfer')
|
|
71
|
-
const exportResponse =
|
|
70
|
+
const exportResponse = await this.dataTransferClient.dataExport({
|
|
72
71
|
project: sourceProject,
|
|
73
72
|
includeSystem,
|
|
74
73
|
excludeTables: input.getOption('exclude-table') ?? [],
|
|
75
74
|
gzip: gzipTransfer,
|
|
76
|
-
})
|
|
75
|
+
})
|
|
77
76
|
const stream = Readable.fromWeb(exportResponse.body! as any)
|
|
78
77
|
const importResponse = await this.dataTransferClient.dataImport({
|
|
79
78
|
stream: stream,
|
|
@@ -42,20 +42,22 @@ export class WorkspaceUpdateApiCommand extends Command<Args, Options> {
|
|
|
42
42
|
}
|
|
43
43
|
await this.dockerComposeManager.updateMainDockerComposeConfig(data => ({
|
|
44
44
|
...data,
|
|
45
|
-
services: Object.fromEntries(
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
45
|
+
services: Object.fromEntries(
|
|
46
|
+
Object.entries(data?.services ?? {}).map(([name, service]: [string, any]) => {
|
|
47
|
+
const newImage = getNewImage(service.image)
|
|
48
|
+
if (newImage) {
|
|
49
|
+
console.log(`docker-compose service ${name} updated`)
|
|
50
|
+
return [
|
|
51
|
+
name,
|
|
52
|
+
{
|
|
53
|
+
...service,
|
|
54
|
+
image: newImage,
|
|
55
|
+
},
|
|
56
|
+
]
|
|
57
|
+
}
|
|
58
|
+
return [name, service]
|
|
59
|
+
}),
|
|
60
|
+
),
|
|
59
61
|
}))
|
|
60
62
|
console.log('API versions updated')
|
|
61
63
|
console.log('Restart server to apply changes')
|
package/src/dic.ts
CHANGED
|
@@ -50,11 +50,11 @@ import { DataTransferClient } from './lib/transfer/DataTransferClient'
|
|
|
50
50
|
import { ExportCommand, ImportCommand, TransferCommand } from './commands/transfer'
|
|
51
51
|
import {
|
|
52
52
|
Application,
|
|
53
|
+
Bun,
|
|
53
54
|
CommandFactoryList,
|
|
54
55
|
CommandManager,
|
|
55
56
|
CommandRunner,
|
|
56
57
|
Npm,
|
|
57
|
-
Bun,
|
|
58
58
|
PackageWorkspaceResolver,
|
|
59
59
|
Pnpm,
|
|
60
60
|
Yarn,
|
|
@@ -91,30 +91,17 @@ export const createContainer = ({ env, version, runtime, workspace }: {
|
|
|
91
91
|
runtime: 'node' | 'bun'
|
|
92
92
|
}) => {
|
|
93
93
|
return new Builder({})
|
|
94
|
-
.addService('env', () =>
|
|
95
|
-
|
|
96
|
-
.addService('
|
|
97
|
-
|
|
98
|
-
.addService('
|
|
99
|
-
|
|
100
|
-
.addService('
|
|
101
|
-
|
|
102
|
-
.addService('
|
|
103
|
-
|
|
104
|
-
.addService('
|
|
105
|
-
new YamlHandler(fs))
|
|
106
|
-
.addService('jsExecutor', () =>
|
|
107
|
-
new EvalExecutor())
|
|
108
|
-
.addService('jsBuilder', () =>
|
|
109
|
-
new EsBuildBuilder())
|
|
110
|
-
.addService('jsCodeRunner', ({ jsExecutor, jsBuilder }) =>
|
|
111
|
-
new JsCodeRunner(jsBuilder, jsExecutor))
|
|
112
|
-
|
|
113
|
-
.addService('workspaceResolver', ({ yamlHandler }) =>
|
|
114
|
-
new WorkspaceResolver(yamlHandler))
|
|
115
|
-
|
|
116
|
-
.addService('remoteProjectResolver', ({ env }) =>
|
|
117
|
-
new RemoteProjectResolver(env))
|
|
94
|
+
.addService('env', () => env)
|
|
95
|
+
.addService('version', () => version)
|
|
96
|
+
.addService('runtime', () => runtime)
|
|
97
|
+
.addService('workspace', () => workspace)
|
|
98
|
+
.addService('fs', () => new FileSystem())
|
|
99
|
+
.addService('yamlHandler', ({ fs }) => new YamlHandler(fs))
|
|
100
|
+
.addService('jsExecutor', () => new EvalExecutor())
|
|
101
|
+
.addService('jsBuilder', () => new EsBuildBuilder())
|
|
102
|
+
.addService('jsCodeRunner', ({ jsExecutor, jsBuilder }) => new JsCodeRunner(jsBuilder, jsExecutor))
|
|
103
|
+
.addService('workspaceResolver', ({ yamlHandler }) => new WorkspaceResolver(yamlHandler))
|
|
104
|
+
.addService('remoteProjectResolver', ({ env }) => new RemoteProjectResolver(env))
|
|
118
105
|
.addService('remoteProjectProvider', ({ remoteProjectResolver }) => {
|
|
119
106
|
const provider = new RemoteProjectProvider()
|
|
120
107
|
const remoteProject = remoteProjectResolver.resolve()
|
|
@@ -123,12 +110,9 @@ export const createContainer = ({ env, version, runtime, workspace }: {
|
|
|
123
110
|
}
|
|
124
111
|
return provider
|
|
125
112
|
})
|
|
126
|
-
.addService('systemClientProvider', ({ remoteProjectProvider }) =>
|
|
127
|
-
|
|
128
|
-
.addService('
|
|
129
|
-
new TenantClientProvider(remoteProjectProvider))
|
|
130
|
-
.addService('adminClient', ({ remoteProjectProvider }) =>
|
|
131
|
-
new AdminClient(remoteProjectProvider))
|
|
113
|
+
.addService('systemClientProvider', ({ remoteProjectProvider }) => new SystemClientProvider(remoteProjectProvider))
|
|
114
|
+
.addService('tenantClientProvider', ({ remoteProjectProvider }) => new TenantClientProvider(remoteProjectProvider))
|
|
115
|
+
.addService('adminClient', ({ remoteProjectProvider }) => new AdminClient(remoteProjectProvider))
|
|
132
116
|
.addService('migrationFilesManager', ({ jsCodeRunner, workspace }) => {
|
|
133
117
|
const runJs = runtime === 'bun' ? (file: string) => import(file) : jsCodeRunner.run
|
|
134
118
|
return new MigrationFilesManager(workspace.migrationsDir, {
|
|
@@ -147,16 +131,14 @@ export const createContainer = ({ env, version, runtime, workspace }: {
|
|
|
147
131
|
new Bun(fs, commandRunner),
|
|
148
132
|
])
|
|
149
133
|
})
|
|
150
|
-
.addService(
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
.addService('
|
|
155
|
-
|
|
156
|
-
.addService('migrationsResolver', ({ migrationFilesManager }) =>
|
|
157
|
-
|
|
158
|
-
.addService('schemaVersionBuilder', ({ migrationsResolver, schemaMigrator }) =>
|
|
159
|
-
new SchemaVersionBuilder(migrationsResolver, schemaMigrator))
|
|
134
|
+
.addService(
|
|
135
|
+
'dockerComposeManager',
|
|
136
|
+
({ workspace, env, fs, yamlHandler }) => new DockerComposeManager(workspace.baseDir, env.dockerComposeFile, fs, yamlHandler),
|
|
137
|
+
)
|
|
138
|
+
.addService('modificationHandlerFactory', () => new ModificationHandlerFactory(ModificationHandlerFactory.defaultFactoryMap))
|
|
139
|
+
.addService('schemaMigrator', ({ modificationHandlerFactory }) => new SchemaMigrator(modificationHandlerFactory))
|
|
140
|
+
.addService('migrationsResolver', ({ migrationFilesManager }) => new MigrationsResolver(migrationFilesManager))
|
|
141
|
+
.addService('schemaVersionBuilder', ({ migrationsResolver, schemaMigrator }) => new SchemaVersionBuilder(migrationsResolver, schemaMigrator))
|
|
160
142
|
.addService('schemaDiffer', ({ schemaMigrator }) =>
|
|
161
143
|
new SchemaDiffer(schemaMigrator, {
|
|
162
144
|
maxPatchSize: env.migrationsOptions?.maxPatchSize,
|
|
@@ -167,76 +149,127 @@ export const createContainer = ({ env, version, runtime, workspace }: {
|
|
|
167
149
|
ts: jsSample,
|
|
168
150
|
js: jsSample,
|
|
169
151
|
}))
|
|
170
|
-
.addService('migrationDescriber', ({ modificationHandlerFactory }) =>
|
|
171
|
-
|
|
172
|
-
.addService('
|
|
173
|
-
|
|
174
|
-
.addService(
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
.addService(
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
.addService('
|
|
212
|
-
|
|
213
|
-
.addService(
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
152
|
+
.addService('migrationDescriber', ({ modificationHandlerFactory }) => new MigrationDescriber(modificationHandlerFactory))
|
|
153
|
+
.addService('migrationPrinter', ({ migrationDescriber }) => new MigrationPrinter(migrationDescriber))
|
|
154
|
+
.addService('migrationsExecutor', () => new MigrationExecutor())
|
|
155
|
+
.addService('migrationsStatusResolver', () => new MigrationsStatusResolver())
|
|
156
|
+
.addService(
|
|
157
|
+
'migrationsStatusFacade',
|
|
158
|
+
({ systemClientProvider, migrationsResolver, migrationsStatusResolver, migrationPrinter }) =>
|
|
159
|
+
new MigrationsStatusFacade(systemClientProvider, migrationsResolver, migrationsStatusResolver, migrationPrinter),
|
|
160
|
+
)
|
|
161
|
+
.addService(
|
|
162
|
+
'migrationExecutionFacade',
|
|
163
|
+
({
|
|
164
|
+
systemClientProvider,
|
|
165
|
+
tenantClientProvider,
|
|
166
|
+
remoteProjectProvider,
|
|
167
|
+
schemaVersionBuilder,
|
|
168
|
+
migrationPrinter,
|
|
169
|
+
migrationsExecutor,
|
|
170
|
+
migrationsStatusFacade,
|
|
171
|
+
}) =>
|
|
172
|
+
new MigrationExecutionFacade(
|
|
173
|
+
systemClientProvider,
|
|
174
|
+
tenantClientProvider,
|
|
175
|
+
remoteProjectProvider,
|
|
176
|
+
schemaVersionBuilder,
|
|
177
|
+
migrationPrinter,
|
|
178
|
+
migrationsExecutor,
|
|
179
|
+
migrationsStatusFacade,
|
|
180
|
+
),
|
|
181
|
+
)
|
|
182
|
+
.addService('migrationsValidator', ({ migrationDescriber, schemaMigrator }) => new MigrationsValidator(migrationDescriber, schemaMigrator))
|
|
183
|
+
.addService(
|
|
184
|
+
'migrationRebaseFacade',
|
|
185
|
+
({ schemaVersionBuilder, migrationsValidator, systemClientProvider, migrationFilesManager }) =>
|
|
186
|
+
new MigrationRebaseFacade(schemaVersionBuilder, migrationsValidator, systemClientProvider, migrationFilesManager),
|
|
187
|
+
)
|
|
188
|
+
.addService(
|
|
189
|
+
'schemaLoader',
|
|
190
|
+
({ workspace, jsCodeRunner, runtime }) =>
|
|
191
|
+
runtime === 'bun' ? new ImportSchemaLoader(workspace) : new TranspilingSchemaLoader(workspace, jsCodeRunner),
|
|
192
|
+
)
|
|
193
|
+
.addService('adminDeployer', ({ remoteProjectProvider, adminClient, fs }) => new AdminDeployer(remoteProjectProvider, adminClient, fs))
|
|
194
|
+
.addService('dataTransferClient', () => new DataTransferClient())
|
|
195
|
+
.addService(
|
|
196
|
+
'deployCommand',
|
|
197
|
+
({ adminDeployer, migrationExecutionFacade, fs, remoteProjectProvider, remoteProjectResolver, workspace }) =>
|
|
198
|
+
new DeployCommand(adminDeployer, migrationExecutionFacade, fs, remoteProjectProvider, remoteProjectResolver, workspace),
|
|
199
|
+
)
|
|
200
|
+
.addService(
|
|
201
|
+
'migrationAmendCommand',
|
|
202
|
+
({
|
|
203
|
+
migrationsResolver,
|
|
204
|
+
systemClientProvider,
|
|
205
|
+
migrationsStatusFacade,
|
|
206
|
+
schemaLoader,
|
|
207
|
+
schemaVersionBuilder,
|
|
208
|
+
migrationCreator,
|
|
209
|
+
migrationsValidator,
|
|
210
|
+
migrationPrinter,
|
|
211
|
+
schemaMigrator,
|
|
212
|
+
}) =>
|
|
213
|
+
new MigrationAmendCommand(
|
|
214
|
+
migrationsResolver,
|
|
215
|
+
systemClientProvider,
|
|
216
|
+
migrationsStatusFacade,
|
|
217
|
+
schemaLoader,
|
|
218
|
+
schemaVersionBuilder,
|
|
219
|
+
migrationCreator,
|
|
220
|
+
migrationsValidator,
|
|
221
|
+
migrationPrinter,
|
|
222
|
+
schemaMigrator,
|
|
223
|
+
),
|
|
224
|
+
)
|
|
225
|
+
.addService('migrationBlankCommand', ({ migrationCreator }) => new MigrationBlankCommand(migrationCreator))
|
|
226
|
+
.addService(
|
|
227
|
+
'migrationDescribeCommand',
|
|
228
|
+
({ migrationPrinter, schemaVersionBuilder, migrationsResolver }) =>
|
|
229
|
+
new MigrationDescribeCommand(migrationPrinter, schemaVersionBuilder, migrationsResolver),
|
|
230
|
+
)
|
|
231
|
+
.addService(
|
|
232
|
+
'migrationDiffCommand',
|
|
233
|
+
({ schemaLoader, schemaVersionBuilder, migrationCreator, migrationPrinter, migrationExecutionFacade }) =>
|
|
234
|
+
new MigrationDiffCommand(schemaLoader, schemaVersionBuilder, migrationCreator, migrationPrinter, migrationExecutionFacade),
|
|
235
|
+
)
|
|
236
|
+
.addService('migrationExecuteCommand', ({ migrationExecutionFacade }) => new MigrationExecuteCommand(migrationExecutionFacade))
|
|
237
|
+
.addService(
|
|
238
|
+
'migrationRebaseCommand',
|
|
239
|
+
({ migrationsResolver, migrationRebaseFacade }) => new MigrationRebaseCommand(migrationsResolver, migrationRebaseFacade),
|
|
240
|
+
)
|
|
241
|
+
.addService(
|
|
242
|
+
'migrationStatusCommand',
|
|
243
|
+
({ migrationsStatusFacade, migrationFilesManager, systemClientProvider, migrationPrinter }) =>
|
|
244
|
+
new MigrationStatusCommand(migrationsStatusFacade, migrationFilesManager, systemClientProvider, migrationPrinter),
|
|
245
|
+
)
|
|
246
|
+
.addService('versionCommand', ({ version }) => new VersionCommand(version))
|
|
247
|
+
.addService(
|
|
248
|
+
'projectGenerateDocumentationCommand',
|
|
249
|
+
({ schemaLoader, schemaVersionBuilder }) => new ProjectGenerateDocumentationCommand(schemaLoader, schemaVersionBuilder),
|
|
250
|
+
)
|
|
251
|
+
.addService(
|
|
252
|
+
'projectPrintSchemaCommand',
|
|
253
|
+
({ schemaLoader, schemaVersionBuilder }) => new ProjectPrintSchemaCommand(schemaLoader, schemaVersionBuilder),
|
|
254
|
+
)
|
|
255
|
+
.addService(
|
|
256
|
+
'projectValidateCommand',
|
|
257
|
+
({ schemaLoader, migrationsValidator, migrationsResolver, schemaDiffer, schemaVersionBuilder }) =>
|
|
258
|
+
new ProjectValidateCommand(schemaLoader, migrationsValidator, migrationsResolver, schemaDiffer, schemaVersionBuilder),
|
|
259
|
+
)
|
|
260
|
+
.addService('exportCommand', ({ dataTransferClient, remoteProjectResolver }) => new ExportCommand(remoteProjectResolver, dataTransferClient))
|
|
261
|
+
.addService('importCommand', ({ dataTransferClient, remoteProjectResolver }) => new ImportCommand(remoteProjectResolver, dataTransferClient))
|
|
262
|
+
.addService('transferCommand', ({ dataTransferClient, remoteProjectResolver }) => new TransferCommand(remoteProjectResolver, dataTransferClient))
|
|
263
|
+
.addService(
|
|
264
|
+
'workspaceUpdateCommand',
|
|
265
|
+
({ packageWorkspaceResolver, dockerComposeManager }) => new WorkspaceUpdateApiCommand(packageWorkspaceResolver, dockerComposeManager),
|
|
266
|
+
)
|
|
267
|
+
.addService('actionsListVariables', ({ remoteProjectResolver }) => new ActionsListVariablesCommand(remoteProjectResolver))
|
|
268
|
+
.addService('actionsSetVariables', ({ remoteProjectResolver }) => new ActionsSetVariablesCommand(remoteProjectResolver))
|
|
269
|
+
.addService('actionsListFailedEvents', ({ remoteProjectResolver }) => new ActionsListFailedEventsCommand(remoteProjectResolver))
|
|
270
|
+
.addService('actionsRetryEvent', ({ remoteProjectResolver }) => new ActionsRetryEventCommand(remoteProjectResolver))
|
|
271
|
+
.addService('actionsGetEvent', ({ remoteProjectResolver }) => new ActionsGetEventCommand(remoteProjectResolver))
|
|
272
|
+
.addService('actionsStopEvent', ({ remoteProjectResolver }) => new ActionsStopEventCommand(remoteProjectResolver))
|
|
240
273
|
.addService('commandList', dic => {
|
|
241
274
|
const commands: CommandFactoryList = {
|
|
242
275
|
['deploy']: () => dic.deployCommand,
|
|
@@ -264,11 +297,12 @@ export const createContainer = ({ env, version, runtime, workspace }: {
|
|
|
264
297
|
}
|
|
265
298
|
return commands
|
|
266
299
|
})
|
|
267
|
-
.addService('commandManager', ({ commandList }) =>
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
300
|
+
.addService('commandManager', ({ commandList }) => new CommandManager(commandList))
|
|
301
|
+
.addService(
|
|
302
|
+
'versionChecker',
|
|
303
|
+
({ version, workspace, packageWorkspaceResolver, dockerComposeManager }) =>
|
|
304
|
+
new VersionChecker(version, workspace.baseDir, packageWorkspaceResolver, dockerComposeManager),
|
|
305
|
+
)
|
|
272
306
|
.addService('application', ({ commandManager, versionChecker }) => {
|
|
273
307
|
const app = new Application(
|
|
274
308
|
commandManager,
|
|
@@ -63,10 +63,8 @@ export class VersionChecker {
|
|
|
63
63
|
Please make sure all dependencies are up to date.\nIf you are really certain about the compatibility, you can disable this version check by running the CLI with the CONTEMBER_SKIP_VERSION_CHECK=1 environment variable`
|
|
64
64
|
}
|
|
65
65
|
}
|
|
66
|
-
|
|
67
66
|
}
|
|
68
67
|
|
|
69
|
-
|
|
70
68
|
const extractVersion = (tag: string) => {
|
|
71
69
|
// e.g.
|
|
72
70
|
// 2.1.0-alpha.15-foo-bar => 2.1.0-alpha.15
|
|
@@ -14,7 +14,8 @@ export class AdminClient {
|
|
|
14
14
|
if (!response.ok) {
|
|
15
15
|
const project = this.remoteProjectProvider.get()
|
|
16
16
|
const maskedToken = maskToken(project.token)
|
|
17
|
-
throw `Failed to deploy admin, POST request to ${project.adminEndpoint}/_deploy with token ${maskedToken} returned status ${response.status} ${response.statusText}\n${await response
|
|
17
|
+
throw `Failed to deploy admin, POST request to ${project.adminEndpoint}/_deploy with token ${maskedToken} returned status ${response.status} ${response.statusText}\n${await response
|
|
18
|
+
.text()}`
|
|
18
19
|
}
|
|
19
20
|
}
|
|
20
21
|
|
|
@@ -29,5 +30,4 @@ export class AdminClient {
|
|
|
29
30
|
body: JSON.stringify(body),
|
|
30
31
|
})
|
|
31
32
|
}
|
|
32
|
-
|
|
33
33
|
}
|
|
@@ -25,7 +25,6 @@ export class AdminDeployer {
|
|
|
25
25
|
console.log(`Admin deployed (${files.length} files)`)
|
|
26
26
|
}
|
|
27
27
|
|
|
28
|
-
|
|
29
28
|
private readAdminFiles = async (dir: string, prefix: string = ''): Promise<AdminFiles> => {
|
|
30
29
|
const files = []
|
|
31
30
|
for (const fileName of await this.fs.readDir(dir, { withFileTypes: true })) {
|
|
@@ -18,10 +18,8 @@ export interface DockerComposeConfig {
|
|
|
18
18
|
services?: Record<string, DockerComposeServiceConfig>
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
-
|
|
22
21
|
const MAIN_CONFIGS = ['docker-compose.yaml', 'docker-compose.yml']
|
|
23
22
|
|
|
24
|
-
|
|
25
23
|
export class DockerComposeManager {
|
|
26
24
|
constructor(
|
|
27
25
|
private readonly dir: string,
|
|
@@ -59,5 +57,4 @@ export class DockerComposeManager {
|
|
|
59
57
|
}
|
|
60
58
|
return null
|
|
61
59
|
}
|
|
62
|
-
|
|
63
60
|
}
|
|
@@ -11,7 +11,6 @@ export class MigrationsStatusFacade {
|
|
|
11
11
|
) {
|
|
12
12
|
}
|
|
13
13
|
|
|
14
|
-
|
|
15
14
|
public resolveMigrationsStatus = async ({ force, allowError }: { force?: boolean; allowError?: boolean }) => {
|
|
16
15
|
const executedMigrations = await this.systemClientProvider.get().listExecutedMigrations()
|
|
17
16
|
const localMigrations = await this.migrationsResolver.getMigrationFiles()
|
|
@@ -13,9 +13,9 @@ export class RemoteProjectResolver {
|
|
|
13
13
|
let token: string | undefined
|
|
14
14
|
let project: string | undefined
|
|
15
15
|
if (identifier?.includes('://')) {
|
|
16
|
-
({ endpoint, project, token } = parseDsn(identifier))
|
|
16
|
+
;({ endpoint, project, token } = parseDsn(identifier))
|
|
17
17
|
} else if (this.cliEnv.dsn) {
|
|
18
|
-
({ endpoint, project, token } = parseDsn(this.cliEnv.dsn))
|
|
18
|
+
;({ endpoint, project, token } = parseDsn(this.cliEnv.dsn))
|
|
19
19
|
} else {
|
|
20
20
|
endpoint = this.cliEnv.apiUrl
|
|
21
21
|
token = this.cliEnv.apiToken
|