1
0
Fork 0
mirror of https://github.com/portainer/portainer.git synced 2025-07-19 13:29:41 +02:00

Enable the ability to cordon/uncordon/drain nodes (#4723)

* feat(node): Enable the ability to cordon/uncordon/drain nodes

* feat(cluster): check if there is a drain operation somewhere

* feat(kubernetes): allow to cordon, uncordon, drain nodes

* refacto(kubernetes): set a constant for drain label name

* fix(node): Relocate the warning message next to the dropdown and change the information message
This commit is contained in:
Maxime Bajeux 2021-03-15 22:36:14 +01:00 committed by GitHub
parent 660bc2dadf
commit 32a9a2e46b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
10 changed files with 182 additions and 13 deletions

View file

@ -1,3 +1,5 @@
export const KubernetesPortainerNodeDrainLabel = 'io.portainer/node-status-drain';
/**
* KubernetesNode Model
*/
@ -14,6 +16,7 @@ const _KubernetesNode = Object.freeze({
Api: false,
Taints: [],
Port: 0,
Availability: '',
});
export class KubernetesNode {
@ -58,6 +61,12 @@ export class KubernetesNodeTaint {
}
}
export const KubernetesNodeAvailabilities = Object.freeze({
ACTIVE: 'Active',
PAUSE: 'Pause',
DRAIN: 'Drain',
});
export const KubernetesNodeTaintEffects = Object.freeze({
NOSCHEDULE: 'NoSchedule',
PREFERNOSCHEDULE: 'PreferNoSchedule',