mirror of
https://github.com/moghtech/komodo.git
synced 2026-02-13 15:39:03 -06:00
default all owners to empty array
This commit is contained in:
@@ -16,7 +16,7 @@ export default function deploymentModel() {
|
||||
const schema = new Schema<Deployment>({
|
||||
name: { type: String, unique: true, index: true },
|
||||
containerName: { type: String, unique: true, index: true }, // for auto pull of frontend repo as well
|
||||
owners: [String],
|
||||
owners: { type: [String], default: [] },
|
||||
serverID: { type: String, index: true },
|
||||
buildID: { type: String, index: true }, // if deploying a monitor build
|
||||
/* to create docker run command */
|
||||
@@ -28,11 +28,14 @@ export default function deploymentModel() {
|
||||
restart: String,
|
||||
postImage: String, // interpolated into run command after the image String
|
||||
containerUser: String, // after -u in the run command
|
||||
dockerAccount: String,
|
||||
/* to manage repo for static frontend, mounted as a volume */
|
||||
repo: String,
|
||||
branch: String,
|
||||
containerMount: String, // the file path to mount repo on inside the container
|
||||
subfolder: String,
|
||||
githubAccount: String,
|
||||
containerMount: String, // the file path to mount repo on inside the container
|
||||
repoMount: String,
|
||||
});
|
||||
|
||||
return model("Deployment", schema)
|
||||
|
||||
@@ -19,7 +19,7 @@ const builds = fp((app: FastifyInstance, _: {}, done: () => void) => {
|
||||
cliBuild: Command,
|
||||
dockerBuildArgs: DockerBuildArgs,
|
||||
dockerAccount: String,
|
||||
owners: [String],
|
||||
owners: { type: [String], default: [] },
|
||||
});
|
||||
|
||||
app.decorate("builds", model(app, "Build", schema));
|
||||
|
||||
@@ -9,7 +9,7 @@ const deployments = fp((app: FastifyInstance, _: {}, done: () => void) => {
|
||||
const schema = new Schema<Deployment>({
|
||||
name: { type: String, unique: true, index: true },
|
||||
containerName: { type: String, unique: true, index: true }, // for auto pull of frontend repo as well
|
||||
owners: [String],
|
||||
owners: { type: [String], default: [] },
|
||||
serverID: { type: String, index: true },
|
||||
buildID: { type: String, index: true }, // if deploying a monitor build
|
||||
/* to create docker run command */
|
||||
|
||||
Reference in New Issue
Block a user