fix restart
This commit is contained in:
parent
a18c73bd7c
commit
6ca1d978d4
@ -1446,11 +1446,11 @@ export function convertTolOldVolumeNames(type) {
|
||||
export async function cleanupDockerStorage(dockerId, lowDiskSpace, force) {
|
||||
// Cleanup old coolify images
|
||||
try {
|
||||
let { stdout: images } = await executeDockerCmd({ dockerId, command: `docker images coollabsio/coolify --filter before="coollabsio/coolify:${version}" -q | xargs` })
|
||||
let { stdout: images } = await executeDockerCmd({ dockerId, command: `docker images coollabsio/coolify --filter before="coollabsio/coolify:${version}" -q | xargs -r` })
|
||||
|
||||
images = images.trim();
|
||||
if (images) {
|
||||
await executeDockerCmd({ dockerId, command: `docker rmi -f ${images}" -q | xargs` })
|
||||
await executeDockerCmd({ dockerId, command: `docker rmi -f ${images}" -q | xargs -r` })
|
||||
}
|
||||
} catch (error) {
|
||||
//console.log(error);
|
||||
|
@ -78,7 +78,7 @@ export async function restartCoolify(request: FastifyRequest<any>) {
|
||||
const teamId = request.user.teamId;
|
||||
if (teamId === '0') {
|
||||
if (!isDev) {
|
||||
await asyncExecShell(`docker restart coolify`);
|
||||
asyncExecShell(`docker restart coolify`);
|
||||
return {};
|
||||
} else {
|
||||
console.log('Restarting Coolify')
|
||||
|
@ -42,6 +42,7 @@
|
||||
loading.restart = true;
|
||||
try {
|
||||
await post(`/internal/restart`, {});
|
||||
await asyncSleep(10000);
|
||||
let reachable = false;
|
||||
let tries = 0;
|
||||
do {
|
||||
|
Loading…
x
Reference in New Issue
Block a user