mirror of
https://github.com/andwati/dokploy.git
synced 2026-11-27 05:58:46 +00:00
[autofix.ci] apply automated fixes
This commit is contained in:
@@ -47,8 +47,10 @@ export const EditTraefikEnv = ({ children, serverId }: Props) => {
|
|||||||
const { mutateAsync, isLoading, error, isError } =
|
const { mutateAsync, isLoading, error, isError } =
|
||||||
api.settings.writeTraefikEnv.useMutation();
|
api.settings.writeTraefikEnv.useMutation();
|
||||||
|
|
||||||
const { execute: executeWithHealthCheck, isExecuting: isHealthCheckExecuting } =
|
const {
|
||||||
useHealthCheckAfterMutation({
|
execute: executeWithHealthCheck,
|
||||||
|
isExecuting: isHealthCheckExecuting,
|
||||||
|
} = useHealthCheckAfterMutation({
|
||||||
initialDelay: 5000,
|
initialDelay: 5000,
|
||||||
successMessage: "Traefik Env Updated",
|
successMessage: "Traefik Env Updated",
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -79,8 +79,10 @@ export const ManageTraefikPorts = ({ children, serverId }: Props) => {
|
|||||||
const { mutateAsync: updatePorts, isLoading } =
|
const { mutateAsync: updatePorts, isLoading } =
|
||||||
api.settings.updateTraefikPorts.useMutation();
|
api.settings.updateTraefikPorts.useMutation();
|
||||||
|
|
||||||
const { execute: executeWithHealthCheck, isExecuting: isHealthCheckExecuting } =
|
const {
|
||||||
useHealthCheckAfterMutation({
|
execute: executeWithHealthCheck,
|
||||||
|
isExecuting: isHealthCheckExecuting,
|
||||||
|
} = useHealthCheckAfterMutation({
|
||||||
initialDelay: 5000,
|
initialDelay: 5000,
|
||||||
successMessage: t("settings.server.webServer.traefik.portsUpdated"),
|
successMessage: t("settings.server.webServer.traefik.portsUpdated"),
|
||||||
onSuccess: () => {
|
onSuccess: () => {
|
||||||
|
|||||||
@@ -66,13 +66,7 @@ export const useHealthCheckAfterMutation = ({
|
|||||||
|
|
||||||
await new Promise((resolve) => setTimeout(resolve, pollInterval));
|
await new Promise((resolve) => setTimeout(resolve, pollInterval));
|
||||||
await pollUntilHealthy();
|
await pollUntilHealthy();
|
||||||
}, [
|
}, [checkHealth, successMessage, reloadOnSuccess, onSuccess, pollInterval]);
|
||||||
checkHealth,
|
|
||||||
successMessage,
|
|
||||||
reloadOnSuccess,
|
|
||||||
onSuccess,
|
|
||||||
pollInterval,
|
|
||||||
]);
|
|
||||||
|
|
||||||
const execute = useCallback(
|
const execute = useCallback(
|
||||||
async <T>(mutationFn: () => Promise<T>): Promise<T> => {
|
async <T>(mutationFn: () => Promise<T>): Promise<T> => {
|
||||||
|
|||||||
Reference in New Issue
Block a user