diff --git a/apps/api/src/jobs/infrastructure.ts b/apps/api/src/jobs/infrastructure.ts index e0b2d3a61..d14a118ba 100644 --- a/apps/api/src/jobs/infrastructure.ts +++ b/apps/api/src/jobs/infrastructure.ts @@ -146,7 +146,7 @@ async function checkProxies() { const { destinationDockerId, destinationDocker, publicPort, id } = database; if (destinationDockerId && destinationDocker.isCoolifyProxyUsed) { const { privatePort } = generateDatabaseConfiguration(database, arch); - portReachable = await isReachable(publicPort, { host: destinationDocker.remoteIpAddress || ipv4 || ipv6 }) + portReachable = await isReachable(publicPort, { host: isDev ? 'localhost' : destinationDocker.remoteIpAddress || ipv4 || ipv6 }) if (!portReachable) { await startTraefikTCPProxy(destinationDocker, id, publicPort, privatePort); } @@ -160,7 +160,7 @@ async function checkProxies() { const { service, ftpPublicPort } = ftp; const { destinationDockerId, destinationDocker, id } = service; if (destinationDockerId && destinationDocker.isCoolifyProxyUsed) { - portReachable = await isReachable(ftpPublicPort, { host: destinationDocker.remoteIpAddress || ipv4 || ipv6 }) + portReachable = await isReachable(ftpPublicPort, { host: isDev ? 'localhost' : destinationDocker.remoteIpAddress || ipv4 || ipv6 }) if (!portReachable) { await startTraefikTCPProxy(destinationDocker, id, ftpPublicPort, 22, 'wordpressftp'); } @@ -176,7 +176,7 @@ async function checkProxies() { const { service, publicPort } = minio; const { destinationDockerId, destinationDocker, id } = service; if (destinationDockerId && destinationDocker.isCoolifyProxyUsed) { - portReachable = await isReachable(publicPort, { host: destinationDocker.remoteIpAddress || ipv4 || ipv6 }) + portReachable = await isReachable(publicPort, { host: isDev ? 'localhost' : destinationDocker.remoteIpAddress || ipv4 || ipv6 }) if (!portReachable) { await startTraefikTCPProxy(destinationDocker, id, publicPort, 9000); } diff --git a/apps/api/src/lib/common.ts b/apps/api/src/lib/common.ts index e8d12c97e..ce38724f3 100644 --- a/apps/api/src/lib/common.ts +++ b/apps/api/src/lib/common.ts @@ -1365,7 +1365,7 @@ export async function startTraefikTCPProxy( let dependentId = id; if (type === 'wordpressftp') dependentId = `${id}-ftp`; - const foundDependentContainer = await checkContainer({ + const { found: foundDependentContainer } = await checkContainer({ dockerId, container: dependentId, remove: true