mirror of
https://github.com/Dokploy/dokploy.git
synced 2026-07-01 03:55:22 +02:00
[autofix.ci] apply automated fixes
This commit is contained in:
@@ -203,7 +203,6 @@ export const applications = pgTable("application", {
|
||||
export const applicationsRelations = relations(
|
||||
applications,
|
||||
({ one, many }) => ({
|
||||
|
||||
environment: one(environments, {
|
||||
fields: [applications.environmentId],
|
||||
references: [environments.environmentId],
|
||||
|
||||
@@ -110,7 +110,6 @@ export const compose = pgTable("compose", {
|
||||
});
|
||||
|
||||
export const composeRelations = relations(compose, ({ one, many }) => ({
|
||||
|
||||
environment: one(environments, {
|
||||
fields: [compose.environmentId],
|
||||
references: [environments.environmentId],
|
||||
|
||||
@@ -77,7 +77,6 @@ export const mariadb = pgTable("mariadb", {
|
||||
});
|
||||
|
||||
export const mariadbRelations = relations(mariadb, ({ one, many }) => ({
|
||||
|
||||
environment: one(environments, {
|
||||
fields: [mariadb.environmentId],
|
||||
references: [environments.environmentId],
|
||||
|
||||
@@ -74,7 +74,6 @@ export const mongo = pgTable("mongo", {
|
||||
});
|
||||
|
||||
export const mongoRelations = relations(mongo, ({ one, many }) => ({
|
||||
|
||||
environment: one(environments, {
|
||||
fields: [mongo.environmentId],
|
||||
references: [environments.environmentId],
|
||||
|
||||
@@ -75,7 +75,6 @@ export const mysql = pgTable("mysql", {
|
||||
});
|
||||
|
||||
export const mysqlRelations = relations(mysql, ({ one, many }) => ({
|
||||
|
||||
environment: one(environments, {
|
||||
fields: [mysql.environmentId],
|
||||
references: [environments.environmentId],
|
||||
|
||||
@@ -75,7 +75,6 @@ export const postgres = pgTable("postgres", {
|
||||
});
|
||||
|
||||
export const postgresRelations = relations(postgres, ({ one, many }) => ({
|
||||
|
||||
environment: one(environments, {
|
||||
fields: [postgres.environmentId],
|
||||
references: [environments.environmentId],
|
||||
|
||||
@@ -71,7 +71,6 @@ export const redis = pgTable("redis", {
|
||||
});
|
||||
|
||||
export const redisRelations = relations(redis, ({ one, many }) => ({
|
||||
|
||||
environment: one(environments, {
|
||||
fields: [redis.environmentId],
|
||||
references: [environments.environmentId],
|
||||
|
||||
@@ -86,7 +86,6 @@ export const createApplication = async (
|
||||
.returning()
|
||||
.then((value) => value[0]);
|
||||
|
||||
|
||||
if (!newApplication) {
|
||||
throw new TRPCError({
|
||||
code: "BAD_REQUEST",
|
||||
|
||||
@@ -62,7 +62,6 @@ export const findEnvironmentsByProjectId = async (projectId: string) => {
|
||||
};
|
||||
|
||||
export const deleteEnvironment = async (environmentId: string) => {
|
||||
|
||||
const currentEnvironment = await findEnvironmentById(environmentId);
|
||||
if (currentEnvironment.name === "production") {
|
||||
throw new TRPCError({
|
||||
|
||||
@@ -49,8 +49,6 @@ export const findPreviewDeploymentById = async (
|
||||
return application;
|
||||
};
|
||||
|
||||
|
||||
|
||||
export const removePreviewDeployment = async (previewDeploymentId: string) => {
|
||||
try {
|
||||
const previewDeployment =
|
||||
|
||||
@@ -36,13 +36,13 @@ export const createProject = async (
|
||||
}
|
||||
|
||||
// Automatically create a production environment
|
||||
const newEnvironment = await createProductionEnvironment(newProject.projectId);
|
||||
return {
|
||||
project: newProject,
|
||||
environment: newEnvironment,
|
||||
};
|
||||
|
||||
|
||||
const newEnvironment = await createProductionEnvironment(
|
||||
newProject.projectId,
|
||||
);
|
||||
return {
|
||||
project: newProject,
|
||||
environment: newEnvironment,
|
||||
};
|
||||
};
|
||||
|
||||
export const findProjectById = async (projectId: string) => {
|
||||
|
||||
Reference in New Issue
Block a user