1
0
Fork 0
mirror of https://github.com/portainer/portainer.git synced 2025-07-21 14:29:40 +02:00
portainer/app/react/kubernetes/applications/constants.ts
Ali abf517de28
Some checks are pending
ci / build_images (map[arch:amd64 platform:linux]) (push) Waiting to run
ci / build_images (map[arch:amd64 platform:windows version:1809]) (push) Waiting to run
ci / build_images (map[arch:amd64 platform:windows version:ltsc2022]) (push) Waiting to run
ci / build_images (map[arch:arm64 platform:linux]) (push) Waiting to run
ci / build_manifests (push) Blocked by required conditions
/ triage (push) Waiting to run
Lint / Run linters (push) Waiting to run
Test / test-client (push) Waiting to run
Test / test-server (map[arch:amd64 platform:linux]) (push) Waiting to run
Test / test-server (map[arch:amd64 platform:windows version:1809]) (push) Waiting to run
Test / test-server (map[arch:amd64 platform:windows version:ltsc2022]) (push) Waiting to run
Test / test-server (map[arch:arm64 platform:linux]) (push) Waiting to run
refactor(app): migrate app summary section [EE-6239] (#10910)
2024-01-05 15:42:36 +13:00

34 lines
1.4 KiB
TypeScript

import { AppKind, DeploymentType } from './types';
// Portainer specific labels
export const appStackNameLabel = 'io.portainer.kubernetes.application.stack';
export const appStackIdLabel = 'io.portainer.kubernetes.application.stackid';
export const appOwnerLabel = 'io.portainer.kubernetes.application.owner';
export const appNoteAnnotation = 'io.portainer.kubernetes.application.note';
export const appDeployMethodLabel = 'io.portainer.kubernetes.application.kind';
export const defaultDeploymentUniqueLabel = 'pod-template-hash';
export const appNameLabel = 'io.portainer.kubernetes.application.name';
export const appRevisionAnnotation = 'deployment.kubernetes.io/revision';
// unchangedAnnotationKeysForRollbackPatch lists the annotations that should be preserved from the deployment and not
// copied from the replicaset when rolling a deployment back
export const unchangedAnnotationKeysForRollbackPatch = [
'kubectl.kubernetes.io/last-applied-configuration',
appRevisionAnnotation,
'deployment.kubernetes.io/revision-history',
'deployment.kubernetes.io/desired-replicas',
'deployment.kubernetes.io/max-replicas',
'deprecated.deployment.rollback.to',
'deprecated.daemonset.template.generation',
];
export const appKindToDeploymentTypeMap: Record<
AppKind,
DeploymentType | null
> = {
Deployment: 'Replicated',
StatefulSet: 'Replicated',
DaemonSet: 'Global',
Pod: null,
} as const;