mirror of
https://github.com/portainer/portainer.git
synced 2025-07-22 23:09:41 +02:00
fix(app): various persisted folder fixes [EE-6235] (#10963)
Co-authored-by: testa113 <testa113>
This commit is contained in:
parent
7a04d1d4ea
commit
95474b7dc5
9 changed files with 84 additions and 78 deletions
|
@ -59,9 +59,13 @@ function getOptions(
|
|||
label: 'Shared',
|
||||
description:
|
||||
'Application will be deployed as a Deployment with a shared storage access',
|
||||
tooltip: () =>
|
||||
isEdit ? 'Changing the data access policy is not allowed' : '',
|
||||
disabled: () => isEdit && value !== 'Shared',
|
||||
tooltip: () => {
|
||||
if (persistedFoldersUseExistingVolumes) {
|
||||
return 'Changing the data access policy is not allowed';
|
||||
}
|
||||
return '';
|
||||
},
|
||||
disabled: () => persistedFoldersUseExistingVolumes,
|
||||
},
|
||||
] as const;
|
||||
}
|
||||
|
|
|
@ -1,34 +0,0 @@
|
|||
import { Boxes, Sliders } from 'lucide-react';
|
||||
|
||||
import { BoxSelectorOption } from '@@/BoxSelector';
|
||||
|
||||
import { DeploymentType } from '../types';
|
||||
|
||||
export function getDeploymentOptions(
|
||||
supportGlobalDeployment: boolean
|
||||
): ReadonlyArray<BoxSelectorOption<DeploymentType>> {
|
||||
return [
|
||||
{
|
||||
id: 'deployment_replicated',
|
||||
label: 'Replicated',
|
||||
value: 'Replicated',
|
||||
icon: Sliders,
|
||||
iconType: 'badge',
|
||||
description: 'Run one or multiple instances of this container',
|
||||
},
|
||||
{
|
||||
id: 'deployment_global',
|
||||
disabled: () => !supportGlobalDeployment,
|
||||
tooltip: () =>
|
||||
!supportGlobalDeployment
|
||||
? 'The storage or access policy used for persisted folders cannot be used with this option'
|
||||
: '',
|
||||
label: 'Global',
|
||||
description:
|
||||
'Application will be deployed as a DaemonSet with an instance on each node of the cluster',
|
||||
value: 'Global',
|
||||
icon: Boxes,
|
||||
iconType: 'badge',
|
||||
},
|
||||
] as const;
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue