Skip to content

Commit

Permalink
Merge pull request #6864 from debsmita1/pod-donut-text
Browse files Browse the repository at this point in the history
fix pod donut information
  • Loading branch information
openshift-merge-robot committed Oct 28, 2020
2 parents ec57c34 + 4a3bf04 commit b28cfab
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 4 deletions.
Expand Up @@ -33,7 +33,7 @@ const PodRingSet: React.FC<PodRingSetProps> = ({ podData, resourceKind, obj, pat
<PodRing
key={inProgressDeploymentData ? 'deploy' : 'notDeploy'}
pods={completedDeploymentData}
rc={completedRC}
rc={podData.isRollingOut ? completedRC : undefined}
resourceKind={resourceKind}
obj={obj}
path={path}
Expand Down
1 change: 1 addition & 0 deletions frontend/packages/console-shared/src/constants/resource.ts
Expand Up @@ -30,6 +30,7 @@ export const TRIGGERS_ANNOTATION = 'image.openshift.io/triggers';
export enum DEPLOYMENT_STRATEGY {
rolling = 'Rolling',
recreate = 'Recreate',
rollingUpdate = 'RollingUpdate',
}

export enum DEPLOYMENT_PHASE {
Expand Down
4 changes: 3 additions & 1 deletion frontend/packages/console-shared/src/utils/pod-utils.ts
Expand Up @@ -193,7 +193,9 @@ export const getPodData = (

// Deploy - Rolling - Recreate
if (
(strategy === DEPLOYMENT_STRATEGY.recreate || strategy === DEPLOYMENT_STRATEGY.rolling) &&
(strategy === DEPLOYMENT_STRATEGY.recreate ||
strategy === DEPLOYMENT_STRATEGY.rolling ||
strategy === DEPLOYMENT_STRATEGY.rollingUpdate) &&
isRollingOut
) {
return {
Expand Down
Expand Up @@ -96,8 +96,8 @@ export const mergeData = (originalResource: K8sResourceKind, newResource: K8sRes
if (mergedData.spec?.template?.spec?.containers) {
mergedData.spec.template.spec.containers = newResource.spec.template.spec.containers;
}
if (mergedData?.spec?.strategy) {
mergedData.spec.strategy = newResource.spec.strategy;
if (mergedData?.spec?.hasOwnProperty('strategy')) {
mergedData.spec.strategy = newResource.spec?.strategy ?? originalResource?.spec?.strategy;
}
if (mergedData.spec?.triggers) {
mergedData.spec.triggers = newResource.spec.triggers;
Expand Down

0 comments on commit b28cfab

Please sign in to comment.