fix: deployment status handling when deployment is missing but app created

This commit is contained in:
biersoeckli
2025-12-16 08:04:11 +00:00
parent 76f92f8a56
commit 405a5ea91f
6 changed files with 19 additions and 5 deletions

View File

@@ -33,6 +33,15 @@ export const getAllPodsStatus = async () =>
dep.metadata?.name === app.id
);
if (!deploymentInfo) {
allAppPods.push({
appId: app.id,
appName: app.name,
projectId: project.id,
projectName: project.name,
replicas: undefined,
readyReplicas: undefined,
deploymentStatus: 'SHUTDOWN' // nothing is deployed, so maybe the app is just created in the database and not started yet
});
continue;
}
const deploymentStatus = deploymentService.mapReplicasetToStatus(deploymentInfo);

View File

@@ -3,7 +3,6 @@ import { Inter } from "next/font/google";
import { cn } from "@/frontend/utils/utils"
import { Toaster } from "@/components/ui/sonner"
import "./globals.css";
import { NavBar } from "./nav-bar";
import { Suspense } from "react";
import FullLoadingSpinner from "@/components/ui/full-loading-spinnter";
import { ConfirmDialog } from "@/components/custom/confirm-dialog";
@@ -14,7 +13,7 @@ import { BreadcrumbsGenerator } from "../components/custom/breadcrumbs-generator
import { getUserSession } from "@/server/utils/action-wrapper.utils";
import { InputDialog } from "@/components/custom/input-dialog";
import userGroupService from "@/server/services/user-group.service";
import PodsStatusPollingProvider from "@/frontend/components/pods-status-polling-provider";
import PodsStatusPollingProvider from "@/components/custom/pods-status-polling-provider";
const inter = Inter({
subsets: ["latin"],

View File

@@ -31,6 +31,8 @@ class MariaDbBackupService {
const endpoint = backupVolume.target.endpoint.includes('http') ? backupVolume.target.endpoint : `https://${backupVolume.target.endpoint}`;
console.log(`S3 Endpoint: ${endpoint}`);
const imageTag = process.env.QS_VERSION?.includes('canary') ? 'canary' : 'latest';
const jobDefinition: V1Job = {
apiVersion: "batch/v1",
kind: "Job",
@@ -49,7 +51,7 @@ class MariaDbBackupService {
containers: [
{
name: jobName,
image: "quickstack/job-backup-mariadb:canary", // todo set to latest image once released
image: "quickstack/job-backup-mariadb:" + imageTag,
env: [
{
name: "MYSQL_HOST",

View File

@@ -32,6 +32,8 @@ class MongoDbBackupService {
const endpoint = backupVolume.target.endpoint.includes('http') ? backupVolume.target.endpoint : `https://${backupVolume.target.endpoint}`;
console.log(`S3 Endpoint: ${endpoint}`);
const imageTag = process.env.QS_VERSION?.includes('canary') ? 'canary' : 'latest';
const jobDefinition: V1Job = {
apiVersion: "batch/v1",
kind: "Job",
@@ -50,7 +52,7 @@ class MongoDbBackupService {
containers: [
{
name: jobName,
image: "quickstack/job-backup-mongodb:canary", // todo set to latest image once released
image: "quickstack/job-backup-mongodb:" + imageTag,
env: [
{
name: "MONGODB_URI",

View File

@@ -31,6 +31,8 @@ class PostgresBackupService {
const endpoint = backupVolume.target.endpoint.includes('http') ? backupVolume.target.endpoint : `https://${backupVolume.target.endpoint}`;
console.log(`S3 Endpoint: ${endpoint}`);
const imageTag = process.env.QS_VERSION?.includes('canary') ? 'canary' : 'latest';
const jobDefinition: V1Job = {
apiVersion: "batch/v1",
kind: "Job",
@@ -49,7 +51,7 @@ class PostgresBackupService {
containers: [
{
name: jobName,
image: "quickstack/job-backup-postgres:canary", // todo set to latest image once released
image: "quickstack/job-backup-postgres:" + imageTag,
env: [
{
name: "POSTGRES_HOST",