fix: Stopping service without proxy

This commit is contained in:
Andras Bacsai 2022-02-15 08:38:16 +01:00
parent 8fc3760eef
commit bdf123bf7b
6 changed files with 31 additions and 7 deletions

View File

@ -33,8 +33,12 @@ export const post: RequestHandler = async (event) => {
} catch (error) {
console.error(error);
}
await stopTcpHttpProxy(destinationDocker, publicPort);
await configureSimpleServiceProxyOff({ domain });
try {
await stopTcpHttpProxy(destinationDocker, publicPort);
await configureSimpleServiceProxyOff({ domain });
} catch (error) {
console.log(error);
}
}
return {

View File

@ -27,7 +27,11 @@ export const post: RequestHandler = async (event) => {
} catch (error) {
console.error(error);
}
await configureSimpleServiceProxyOff({ domain });
try {
await configureSimpleServiceProxyOff({ domain });
} catch (error) {
console.log(error);
}
}
return {

View File

@ -37,7 +37,11 @@ export const post: RequestHandler = async (event) => {
console.error(error);
}
await configureSimpleServiceProxyOff({ domain });
try {
await configureSimpleServiceProxyOff({ domain });
} catch (error) {
console.log(error);
}
}
return {

View File

@ -27,7 +27,11 @@ export const post: RequestHandler = async (event) => {
} catch (error) {
console.error(error);
}
await configureSimpleServiceProxyOff({ domain });
try {
await configureSimpleServiceProxyOff({ domain });
} catch (error) {
console.log(error);
}
}
return {

View File

@ -27,7 +27,11 @@ export const post: RequestHandler = async (event) => {
} catch (error) {
console.error(error);
}
await configureSimpleServiceProxyOff({ domain });
try {
await configureSimpleServiceProxyOff({ domain });
} catch (error) {
console.log(error);
}
}
return {
status: 200

View File

@ -30,7 +30,11 @@ export const post: RequestHandler = async (event) => {
} catch (error) {
console.error(error);
}
await configureSimpleServiceProxyOff({ domain });
try {
await configureSimpleServiceProxyOff({ domain });
} catch (error) {
console.log(error);
}
}
return {