From 5d8ebd027ec996580375d2e6952f811d10bb9bea Mon Sep 17 00:00:00 2001 From: Mauricio Siu <47042324+Siumauricio@users.noreply.github.com> Date: Sun, 29 Dec 2024 13:53:38 -0600 Subject: [PATCH 1/3] fix: parse correctly numbers --- .../show-application-advanced-settings.tsx | 26 ++++++++++--------- 1 file changed, 14 insertions(+), 12 deletions(-) diff --git a/apps/dokploy/components/dashboard/application/advanced/show-application-advanced-settings.tsx b/apps/dokploy/components/dashboard/application/advanced/show-application-advanced-settings.tsx index e77be2d1..c2d2f1ce 100644 --- a/apps/dokploy/components/dashboard/application/advanced/show-application-advanced-settings.tsx +++ b/apps/dokploy/components/dashboard/application/advanced/show-application-advanced-settings.tsx @@ -172,12 +172,13 @@ export const ShowApplicationResources = ({ applicationId }: Props) => { value={field.value?.toString() || ""} onChange={(e) => { const value = e.target.value; - if ( - value === "" || - /^[0-9]*\.?[0-9]*$/.test(value) - ) { - const float = Number.parseFloat(value); - field.onChange(float); + if (value === "") { + field.onChange(null); + } else { + const number = Number.parseInt(value, 10); + if (!Number.isNaN(number)) { + field.onChange(number); + } } }} /> @@ -202,12 +203,13 @@ export const ShowApplicationResources = ({ applicationId }: Props) => { value={field.value?.toString() || ""} onChange={(e) => { const value = e.target.value; - if ( - value === "" || - /^[0-9]*\.?[0-9]*$/.test(value) - ) { - const float = Number.parseFloat(value); - field.onChange(float); + if (value === "") { + field.onChange(null); + } else { + const number = Number.parseInt(value, 10); + if (!Number.isNaN(number)) { + field.onChange(number); + } } }} /> From 5558ee3248609e35f3e8beaec515b17b700c5931 Mon Sep 17 00:00:00 2001 From: Mauricio Siu <47042324+Siumauricio@users.noreply.github.com> Date: Sun, 29 Dec 2024 14:10:41 -0600 Subject: [PATCH 2/3] fix: add tooltip and placeholder values --- .../show-application-advanced-settings.tsx | 86 ++++++++++++++--- .../advanced/show-mariadb-resources.tsx | 92 ++++++++++++++---- .../mongo/advanced/show-mongo-resources.tsx | 96 +++++++++++++++---- .../mysql/advanced/show-mysql-resources.tsx | 92 ++++++++++++++---- .../advanced/show-postgres-resources.tsx | 84 ++++++++++++++-- .../redis/advanced/show-redis-resources.tsx | 92 ++++++++++++++---- 6 files changed, 450 insertions(+), 92 deletions(-) diff --git a/apps/dokploy/components/dashboard/application/advanced/show-application-advanced-settings.tsx b/apps/dokploy/components/dashboard/application/advanced/show-application-advanced-settings.tsx index c2d2f1ce..3d53a170 100644 --- a/apps/dokploy/components/dashboard/application/advanced/show-application-advanced-settings.tsx +++ b/apps/dokploy/components/dashboard/application/advanced/show-application-advanced-settings.tsx @@ -22,6 +22,13 @@ import React, { useEffect } from "react"; import { useForm } from "react-hook-form"; import { toast } from "sonner"; import { z } from "zod"; +import { + Tooltip, + TooltipContent, + TooltipProvider, + TooltipTrigger, +} from "@/components/ui/tooltip"; +import { InfoIcon } from "lucide-react"; const addResourcesApplication = z.object({ memoryReservation: z.number().nullable().optional(), @@ -101,10 +108,25 @@ export const ShowApplicationResources = ({ applicationId }: Props) => { name="memoryReservation" render={({ field }) => ( - Memory Reservation +
+ Memory Reservation + + + + + + +

+ Memory soft limit in bytes. Example: 256MB = + 268435456 bytes +

+
+
+
+
{ @@ -120,7 +142,6 @@ export const ShowApplicationResources = ({ applicationId }: Props) => { }} /> -
)} @@ -132,10 +153,25 @@ export const ShowApplicationResources = ({ applicationId }: Props) => { render={({ field }) => { return ( - Memory Limit +
+ Memory Limit + + + + + + +

+ Memory hard limit in bytes. Example: 1GB = + 1073741824 bytes +

+
+
+
+
{ @@ -163,12 +199,26 @@ export const ShowApplicationResources = ({ applicationId }: Props) => { render={({ field }) => { return ( - Cpu Limit +
+ CPU Limit + + + + + + +

+ CPU quota in units of 10^-9 CPUs. Example: 2 + CPUs = 2000000000 +

+
+
+
+
{ const value = e.target.value; @@ -194,12 +244,26 @@ export const ShowApplicationResources = ({ applicationId }: Props) => { render={({ field }) => { return ( - Cpu Reservation +
+ CPU Reservation + + + + + + +

+ CPU shares (relative weight). Example: 1 CPU = + 1000000000 +

+
+
+
+
{ const value = e.target.value; diff --git a/apps/dokploy/components/dashboard/mariadb/advanced/show-mariadb-resources.tsx b/apps/dokploy/components/dashboard/mariadb/advanced/show-mariadb-resources.tsx index 60cdbda0..383aaa40 100644 --- a/apps/dokploy/components/dashboard/mariadb/advanced/show-mariadb-resources.tsx +++ b/apps/dokploy/components/dashboard/mariadb/advanced/show-mariadb-resources.tsx @@ -18,6 +18,13 @@ import { import { Input } from "@/components/ui/input"; import { api } from "@/utils/api"; import { zodResolver } from "@hookform/resolvers/zod"; +import { + TooltipProvider, + TooltipTrigger, + TooltipContent, + Tooltip, +} from "@/components/ui/tooltip"; +import { InfoIcon } from "lucide-react"; import React, { useEffect } from "react"; import { useForm } from "react-hook-form"; import { toast } from "sonner"; @@ -100,28 +107,40 @@ export const ShowMariadbResources = ({ mariadbId }: Props) => { name="memoryReservation" render={({ field }) => ( - Memory Reservation +
+ Memory Reservation + + + + + + +

+ Memory soft limit in bytes. Example: 256MB = + 268435456 bytes +

+
+
+
+
{ const value = e.target.value; if (value === "") { - // Si el campo está vacío, establece el valor como null. field.onChange(null); } else { const number = Number.parseInt(value, 10); if (!Number.isNaN(number)) { - // Solo actualiza el valor si se convierte a un número válido. field.onChange(number); } } }} /> -
)} @@ -133,21 +152,34 @@ export const ShowMariadbResources = ({ mariadbId }: Props) => { render={({ field }) => { return ( - Memory Limit +
+ Memory Limit + + + + + + +

+ Memory hard limit in bytes. Example: 1GB = + 1073741824 bytes +

+
+
+
+
{ const value = e.target.value; if (value === "") { - // Si el campo está vacío, establece el valor como null. field.onChange(null); } else { const number = Number.parseInt(value, 10); if (!Number.isNaN(number)) { - // Solo actualiza el valor si se convierte a un número válido. field.onChange(number); } } @@ -166,21 +198,34 @@ export const ShowMariadbResources = ({ mariadbId }: Props) => { render={({ field }) => { return ( - Cpu Limit +
+ CPU Limit + + + + + + +

+ CPU quota in units of 10^-9 CPUs. Example: 2 + CPUs = 2000000000 +

+
+
+
+
{ const value = e.target.value; if (value === "") { - // Si el campo está vacío, establece el valor como null. field.onChange(null); } else { const number = Number.parseInt(value, 10); if (!Number.isNaN(number)) { - // Solo actualiza el valor si se convierte a un número válido. field.onChange(number); } } @@ -198,21 +243,34 @@ export const ShowMariadbResources = ({ mariadbId }: Props) => { render={({ field }) => { return ( - Cpu Reservation +
+ CPU Reservation + + + + + + +

+ CPU shares (relative weight). Example: 1 CPU = + 1000000000 +

+
+
+
+
{ const value = e.target.value; if (value === "") { - // Si el campo está vacío, establece el valor como null. field.onChange(null); } else { const number = Number.parseInt(value, 10); if (!Number.isNaN(number)) { - // Solo actualiza el valor si se convierte a un número válido. field.onChange(number); } } diff --git a/apps/dokploy/components/dashboard/mongo/advanced/show-mongo-resources.tsx b/apps/dokploy/components/dashboard/mongo/advanced/show-mongo-resources.tsx index c18b54a8..e42f5a53 100644 --- a/apps/dokploy/components/dashboard/mongo/advanced/show-mongo-resources.tsx +++ b/apps/dokploy/components/dashboard/mongo/advanced/show-mongo-resources.tsx @@ -19,6 +19,13 @@ import { Input } from "@/components/ui/input"; import { api } from "@/utils/api"; import { zodResolver } from "@hookform/resolvers/zod"; import React, { useEffect } from "react"; +import { + TooltipProvider, + TooltipTrigger, + TooltipContent, + Tooltip, +} from "@/components/ui/tooltip"; +import { InfoIcon } from "lucide-react"; import { useForm } from "react-hook-form"; import { toast } from "sonner"; import { z } from "zod"; @@ -89,10 +96,6 @@ export const ShowMongoResources = ({ mongoId }: Props) => { the changes.
- - Please remember to click Redeploy after modify the resources to - apply the changes. - { name="memoryReservation" render={({ field }) => ( - Memory Reservation +
+ Memory Reservation + + + + + + +

+ Memory soft limit in bytes. Example: 256MB = + 268435456 bytes +

+
+
+
+
{ const value = e.target.value; if (value === "") { - // Si el campo está vacío, establece el valor como null. field.onChange(null); } else { const number = Number.parseInt(value, 10); if (!Number.isNaN(number)) { - // Solo actualiza el valor si se convierte a un número válido. field.onChange(number); } } }} /> -
)} @@ -137,21 +152,34 @@ export const ShowMongoResources = ({ mongoId }: Props) => { render={({ field }) => { return ( - Memory Limit +
+ Memory Limit + + + + + + +

+ Memory hard limit in bytes. Example: 1GB = + 1073741824 bytes +

+
+
+
+
{ const value = e.target.value; if (value === "") { - // Si el campo está vacío, establece el valor como null. field.onChange(null); } else { const number = Number.parseInt(value, 10); if (!Number.isNaN(number)) { - // Solo actualiza el valor si se convierte a un número válido. field.onChange(number); } } @@ -170,21 +198,34 @@ export const ShowMongoResources = ({ mongoId }: Props) => { render={({ field }) => { return ( - Cpu Limit +
+ CPU Limit + + + + + + +

+ CPU quota in units of 10^-9 CPUs. Example: 2 + CPUs = 2000000000 +

+
+
+
+
{ const value = e.target.value; if (value === "") { - // Si el campo está vacío, establece el valor como null. field.onChange(null); } else { const number = Number.parseInt(value, 10); if (!Number.isNaN(number)) { - // Solo actualiza el valor si se convierte a un número válido. field.onChange(number); } } @@ -202,21 +243,34 @@ export const ShowMongoResources = ({ mongoId }: Props) => { render={({ field }) => { return ( - Cpu Reservation +
+ CPU Reservation + + + + + + +

+ CPU shares (relative weight). Example: 1 CPU = + 1000000000 +

+
+
+
+
{ const value = e.target.value; if (value === "") { - // Si el campo está vacío, establece el valor como null. field.onChange(null); } else { const number = Number.parseInt(value, 10); if (!Number.isNaN(number)) { - // Solo actualiza el valor si se convierte a un número válido. field.onChange(number); } } diff --git a/apps/dokploy/components/dashboard/mysql/advanced/show-mysql-resources.tsx b/apps/dokploy/components/dashboard/mysql/advanced/show-mysql-resources.tsx index 07ceeae9..e265139b 100644 --- a/apps/dokploy/components/dashboard/mysql/advanced/show-mysql-resources.tsx +++ b/apps/dokploy/components/dashboard/mysql/advanced/show-mysql-resources.tsx @@ -20,6 +20,13 @@ import { api } from "@/utils/api"; import { zodResolver } from "@hookform/resolvers/zod"; import React, { useEffect } from "react"; import { useForm } from "react-hook-form"; +import { + TooltipProvider, + TooltipTrigger, + TooltipContent, + Tooltip, +} from "@/components/ui/tooltip"; +import { InfoIcon } from "lucide-react"; import { toast } from "sonner"; import { z } from "zod"; @@ -100,28 +107,40 @@ export const ShowMysqlResources = ({ mysqlId }: Props) => { name="memoryReservation" render={({ field }) => ( - Memory Reservation +
+ Memory Reservation + + + + + + +

+ Memory soft limit in bytes. Example: 256MB = + 268435456 bytes +

+
+
+
+
{ const value = e.target.value; if (value === "") { - // Si el campo está vacío, establece el valor como null. field.onChange(null); } else { const number = Number.parseInt(value, 10); if (!Number.isNaN(number)) { - // Solo actualiza el valor si se convierte a un número válido. field.onChange(number); } } }} /> -
)} @@ -133,21 +152,34 @@ export const ShowMysqlResources = ({ mysqlId }: Props) => { render={({ field }) => { return ( - Memory Limit +
+ Memory Limit + + + + + + +

+ Memory hard limit in bytes. Example: 1GB = + 1073741824 bytes +

+
+
+
+
{ const value = e.target.value; if (value === "") { - // Si el campo está vacío, establece el valor como null. field.onChange(null); } else { const number = Number.parseInt(value, 10); if (!Number.isNaN(number)) { - // Solo actualiza el valor si se convierte a un número válido. field.onChange(number); } } @@ -166,21 +198,34 @@ export const ShowMysqlResources = ({ mysqlId }: Props) => { render={({ field }) => { return ( - Cpu Limit +
+ CPU Limit + + + + + + +

+ CPU quota in units of 10^-9 CPUs. Example: 2 + CPUs = 2000000000 +

+
+
+
+
{ const value = e.target.value; if (value === "") { - // Si el campo está vacío, establece el valor como null. field.onChange(null); } else { const number = Number.parseInt(value, 10); if (!Number.isNaN(number)) { - // Solo actualiza el valor si se convierte a un número válido. field.onChange(number); } } @@ -198,21 +243,34 @@ export const ShowMysqlResources = ({ mysqlId }: Props) => { render={({ field }) => { return ( - Cpu Reservation +
+ CPU Reservation + + + + + + +

+ CPU shares (relative weight). Example: 1 CPU = + 1000000000 +

+
+
+
+
{ const value = e.target.value; if (value === "") { - // Si el campo está vacío, establece el valor como null. field.onChange(null); } else { const number = Number.parseInt(value, 10); if (!Number.isNaN(number)) { - // Solo actualiza el valor si se convierte a un número válido. field.onChange(number); } } diff --git a/apps/dokploy/components/dashboard/postgres/advanced/show-postgres-resources.tsx b/apps/dokploy/components/dashboard/postgres/advanced/show-postgres-resources.tsx index 7f224ee2..d417edef 100644 --- a/apps/dokploy/components/dashboard/postgres/advanced/show-postgres-resources.tsx +++ b/apps/dokploy/components/dashboard/postgres/advanced/show-postgres-resources.tsx @@ -21,6 +21,13 @@ import { zodResolver } from "@hookform/resolvers/zod"; import React, { useEffect } from "react"; import { useForm } from "react-hook-form"; import { toast } from "sonner"; +import { + TooltipProvider, + TooltipTrigger, + TooltipContent, + Tooltip, +} from "@/components/ui/tooltip"; +import { InfoIcon } from "lucide-react"; import { z } from "zod"; const addResourcesPostgres = z.object({ @@ -100,10 +107,25 @@ export const ShowPostgresResources = ({ postgresId }: Props) => { name="memoryReservation" render={({ field }) => ( - Memory Reservation +
+ Memory Reservation + + + + + + +

+ Memory soft limit in bytes. Example: 256MB = + 268435456 bytes +

+
+
+
+
{ @@ -119,7 +141,6 @@ export const ShowPostgresResources = ({ postgresId }: Props) => { }} /> -
)} @@ -131,10 +152,25 @@ export const ShowPostgresResources = ({ postgresId }: Props) => { render={({ field }) => { return ( - Memory Limit +
+ Memory Limit + + + + + + +

+ Memory hard limit in bytes. Example: 1GB = + 1073741824 bytes +

+
+
+
+
{ @@ -162,10 +198,25 @@ export const ShowPostgresResources = ({ postgresId }: Props) => { render={({ field }) => { return ( - Cpu Limit +
+ CPU Limit + + + + + + +

+ CPU quota in units of 10^-9 CPUs. Example: 2 + CPUs = 2000000000 +

+
+
+
+
{ @@ -192,10 +243,25 @@ export const ShowPostgresResources = ({ postgresId }: Props) => { render={({ field }) => { return ( - Cpu Reservation +
+ CPU Reservation + + + + + + +

+ CPU shares (relative weight). Example: 1 CPU = + 1000000000 +

+
+
+
+
{ diff --git a/apps/dokploy/components/dashboard/redis/advanced/show-redis-resources.tsx b/apps/dokploy/components/dashboard/redis/advanced/show-redis-resources.tsx index 1e719399..ed26d868 100644 --- a/apps/dokploy/components/dashboard/redis/advanced/show-redis-resources.tsx +++ b/apps/dokploy/components/dashboard/redis/advanced/show-redis-resources.tsx @@ -21,6 +21,13 @@ import { zodResolver } from "@hookform/resolvers/zod"; import React, { useEffect } from "react"; import { useForm } from "react-hook-form"; import { toast } from "sonner"; +import { + TooltipProvider, + TooltipTrigger, + TooltipContent, + Tooltip, +} from "@/components/ui/tooltip"; +import { InfoIcon } from "lucide-react"; import { z } from "zod"; const addResourcesRedis = z.object({ @@ -100,28 +107,40 @@ export const ShowRedisResources = ({ redisId }: Props) => { name="memoryReservation" render={({ field }) => ( - Memory Reservation +
+ Memory Reservation + + + + + + +

+ Memory soft limit in bytes. Example: 256MB = + 268435456 bytes +

+
+
+
+
{ const value = e.target.value; if (value === "") { - // Si el campo está vacío, establece el valor como null. field.onChange(null); } else { const number = Number.parseInt(value, 10); if (!Number.isNaN(number)) { - // Solo actualiza el valor si se convierte a un número válido. field.onChange(number); } } }} /> -
)} @@ -133,21 +152,34 @@ export const ShowRedisResources = ({ redisId }: Props) => { render={({ field }) => { return ( - Memory Limit +
+ Memory Limit + + + + + + +

+ Memory hard limit in bytes. Example: 1GB = + 1073741824 bytes +

+
+
+
+
{ const value = e.target.value; if (value === "") { - // Si el campo está vacío, establece el valor como null. field.onChange(null); } else { const number = Number.parseInt(value, 10); if (!Number.isNaN(number)) { - // Solo actualiza el valor si se convierte a un número válido. field.onChange(number); } } @@ -166,21 +198,34 @@ export const ShowRedisResources = ({ redisId }: Props) => { render={({ field }) => { return ( - Cpu Limit +
+ CPU Limit + + + + + + +

+ CPU quota in units of 10^-9 CPUs. Example: 2 + CPUs = 2000000000 +

+
+
+
+
{ const value = e.target.value; if (value === "") { - // Si el campo está vacío, establece el valor como null. field.onChange(null); } else { const number = Number.parseInt(value, 10); if (!Number.isNaN(number)) { - // Solo actualiza el valor si se convierte a un número válido. field.onChange(number); } } @@ -198,21 +243,34 @@ export const ShowRedisResources = ({ redisId }: Props) => { render={({ field }) => { return ( - Cpu Reservation +
+ CPU Reservation + + + + + + +

+ CPU shares (relative weight). Example: 1 CPU = + 1000000000 +

+
+
+
+
{ const value = e.target.value; if (value === "") { - // Si el campo está vacío, establece el valor como null. field.onChange(null); } else { const number = Number.parseInt(value, 10); if (!Number.isNaN(number)) { - // Solo actualiza el valor si se convierte a un número válido. field.onChange(number); } } From 46a5adf793ac2e87cb25b81cc78152c32b181601 Mon Sep 17 00:00:00 2001 From: Mauricio Siu <47042324+Siumauricio@users.noreply.github.com> Date: Sun, 29 Dec 2024 14:17:15 -0600 Subject: [PATCH 3/3] refactor: remove muted text --- .../advanced/show-application-advanced-settings.tsx | 6 +++--- .../dashboard/mariadb/advanced/show-mariadb-resources.tsx | 6 +++--- .../dashboard/mongo/advanced/show-mongo-resources.tsx | 6 +++--- .../dashboard/mysql/advanced/show-mysql-resources.tsx | 6 +++--- .../dashboard/postgres/advanced/show-postgres-resources.tsx | 6 +++--- .../dashboard/redis/advanced/show-redis-resources.tsx | 6 +++--- 6 files changed, 18 insertions(+), 18 deletions(-) diff --git a/apps/dokploy/components/dashboard/application/advanced/show-application-advanced-settings.tsx b/apps/dokploy/components/dashboard/application/advanced/show-application-advanced-settings.tsx index 3d53a170..402e6e23 100644 --- a/apps/dokploy/components/dashboard/application/advanced/show-application-advanced-settings.tsx +++ b/apps/dokploy/components/dashboard/application/advanced/show-application-advanced-settings.tsx @@ -161,7 +161,7 @@ export const ShowApplicationResources = ({ applicationId }: Props) => { -

+

Memory hard limit in bytes. Example: 1GB = 1073741824 bytes

@@ -207,7 +207,7 @@ export const ShowApplicationResources = ({ applicationId }: Props) => { -

+

CPU quota in units of 10^-9 CPUs. Example: 2 CPUs = 2000000000

@@ -252,7 +252,7 @@ export const ShowApplicationResources = ({ applicationId }: Props) => { -

+

CPU shares (relative weight). Example: 1 CPU = 1000000000

diff --git a/apps/dokploy/components/dashboard/mariadb/advanced/show-mariadb-resources.tsx b/apps/dokploy/components/dashboard/mariadb/advanced/show-mariadb-resources.tsx index 383aaa40..7db0555e 100644 --- a/apps/dokploy/components/dashboard/mariadb/advanced/show-mariadb-resources.tsx +++ b/apps/dokploy/components/dashboard/mariadb/advanced/show-mariadb-resources.tsx @@ -160,7 +160,7 @@ export const ShowMariadbResources = ({ mariadbId }: Props) => { -

+

Memory hard limit in bytes. Example: 1GB = 1073741824 bytes

@@ -206,7 +206,7 @@ export const ShowMariadbResources = ({ mariadbId }: Props) => { -

+

CPU quota in units of 10^-9 CPUs. Example: 2 CPUs = 2000000000

@@ -251,7 +251,7 @@ export const ShowMariadbResources = ({ mariadbId }: Props) => { -

+

CPU shares (relative weight). Example: 1 CPU = 1000000000

diff --git a/apps/dokploy/components/dashboard/mongo/advanced/show-mongo-resources.tsx b/apps/dokploy/components/dashboard/mongo/advanced/show-mongo-resources.tsx index e42f5a53..1c497611 100644 --- a/apps/dokploy/components/dashboard/mongo/advanced/show-mongo-resources.tsx +++ b/apps/dokploy/components/dashboard/mongo/advanced/show-mongo-resources.tsx @@ -160,7 +160,7 @@ export const ShowMongoResources = ({ mongoId }: Props) => { -

+

Memory hard limit in bytes. Example: 1GB = 1073741824 bytes

@@ -206,7 +206,7 @@ export const ShowMongoResources = ({ mongoId }: Props) => { -

+

CPU quota in units of 10^-9 CPUs. Example: 2 CPUs = 2000000000

@@ -251,7 +251,7 @@ export const ShowMongoResources = ({ mongoId }: Props) => { -

+

CPU shares (relative weight). Example: 1 CPU = 1000000000

diff --git a/apps/dokploy/components/dashboard/mysql/advanced/show-mysql-resources.tsx b/apps/dokploy/components/dashboard/mysql/advanced/show-mysql-resources.tsx index e265139b..78a524dc 100644 --- a/apps/dokploy/components/dashboard/mysql/advanced/show-mysql-resources.tsx +++ b/apps/dokploy/components/dashboard/mysql/advanced/show-mysql-resources.tsx @@ -160,7 +160,7 @@ export const ShowMysqlResources = ({ mysqlId }: Props) => { -

+

Memory hard limit in bytes. Example: 1GB = 1073741824 bytes

@@ -206,7 +206,7 @@ export const ShowMysqlResources = ({ mysqlId }: Props) => { -

+

CPU quota in units of 10^-9 CPUs. Example: 2 CPUs = 2000000000

@@ -251,7 +251,7 @@ export const ShowMysqlResources = ({ mysqlId }: Props) => { -

+

CPU shares (relative weight). Example: 1 CPU = 1000000000

diff --git a/apps/dokploy/components/dashboard/postgres/advanced/show-postgres-resources.tsx b/apps/dokploy/components/dashboard/postgres/advanced/show-postgres-resources.tsx index d417edef..70d36cef 100644 --- a/apps/dokploy/components/dashboard/postgres/advanced/show-postgres-resources.tsx +++ b/apps/dokploy/components/dashboard/postgres/advanced/show-postgres-resources.tsx @@ -160,7 +160,7 @@ export const ShowPostgresResources = ({ postgresId }: Props) => { -

+

Memory hard limit in bytes. Example: 1GB = 1073741824 bytes

@@ -206,7 +206,7 @@ export const ShowPostgresResources = ({ postgresId }: Props) => { -

+

CPU quota in units of 10^-9 CPUs. Example: 2 CPUs = 2000000000

@@ -251,7 +251,7 @@ export const ShowPostgresResources = ({ postgresId }: Props) => { -

+

CPU shares (relative weight). Example: 1 CPU = 1000000000

diff --git a/apps/dokploy/components/dashboard/redis/advanced/show-redis-resources.tsx b/apps/dokploy/components/dashboard/redis/advanced/show-redis-resources.tsx index ed26d868..9d3c7a14 100644 --- a/apps/dokploy/components/dashboard/redis/advanced/show-redis-resources.tsx +++ b/apps/dokploy/components/dashboard/redis/advanced/show-redis-resources.tsx @@ -160,7 +160,7 @@ export const ShowRedisResources = ({ redisId }: Props) => { -

+

Memory hard limit in bytes. Example: 1GB = 1073741824 bytes

@@ -206,7 +206,7 @@ export const ShowRedisResources = ({ redisId }: Props) => { -

+

CPU quota in units of 10^-9 CPUs. Example: 2 CPUs = 2000000000

@@ -251,7 +251,7 @@ export const ShowRedisResources = ({ redisId }: Props) => { -

+

CPU shares (relative weight). Example: 1 CPU = 1000000000