mirror of
https://github.com/Dokploy/dokploy.git
synced 2026-07-18 20:35:24 +02:00
feat: add support for command arguments in application and database schemas
- Updated the application, mariadb, mongo, mysql, postgres, and redis schemas to include an optional `args` field for command arguments. - Enhanced the AddCommand and ShowCustomCommand components to handle multiple arguments using a dynamic form. - Modified the database build functions to incorporate the new `args` parameter when creating containers. - Added SQL migrations to update the database schema for existing applications and services to accommodate the new `args` field.
This commit is contained in:
@@ -26,6 +26,7 @@ export const buildRedis = async (redis: RedisNested) => {
|
||||
cpuLimit,
|
||||
cpuReservation,
|
||||
command,
|
||||
args,
|
||||
mounts,
|
||||
} = redis;
|
||||
|
||||
@@ -72,11 +73,14 @@ export const buildRedis = async (redis: RedisNested) => {
|
||||
Mounts: [...volumesMount, ...bindsMount, ...filesMount],
|
||||
...(StopGracePeriod !== null &&
|
||||
StopGracePeriod !== undefined && { StopGracePeriod }),
|
||||
Command: ["/bin/sh"],
|
||||
Args: [
|
||||
"-c",
|
||||
command ? command : `redis-server --requirepass ${databasePassword}`,
|
||||
],
|
||||
...(command && {
|
||||
Command: command.split(" "),
|
||||
}),
|
||||
...(args &&
|
||||
args.length > 0 && {
|
||||
Args: args,
|
||||
}),
|
||||
|
||||
Labels,
|
||||
},
|
||||
Networks,
|
||||
|
||||
Reference in New Issue
Block a user