Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[MANOPD-78395] haproxy maintenance mode #216

Merged
merged 8 commits into from
Sep 8, 2022

Conversation

alexarefev
Copy link
Collaborator

@alexarefev alexarefev commented Aug 31, 2022

Description

  • check_paas procedure should work with balancers in maintenance mode

Solution

  • Extend cluster.yaml for the haproxy maintenance mode configuration file preserving
  • Add step in services.haproxy.status task
  • Update documentation

How to apply

Not applicable

Test Cases

TestCase 1

Check if maintenance mode is covered

Test Configuration:

  • Hardware: 4CPU/8GB
  • OS: Ubuntu 20.04
  • Inventory: FullHA, miniHA

Steps:

  1. Install Kubernetes cluster with maintenance_mode: true and maintenance-type: "not bind" for public_cluster_ip
  2. Retart haproxy with maintenance configuration file on each balancer node
  3. Run check_paas procedure

Results:

Before After
Fail Success

Checklist

  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • Integration CI passed
  • Unit tests. If Yes list of new/changed tests with brief description
  • There is no merge conflicts

@koryaga koryaga self-assigned this Sep 1, 2022
@koryaga koryaga added the improvement New feature or request label Sep 1, 2022
@alexarefev alexarefev marked this pull request as ready for review September 1, 2022 12:35
@alexarefev alexarefev marked this pull request as draft September 5, 2022 10:48
@alexarefev alexarefev force-pushed the MANOPD-78395_haproxy_maintenance_check_paas branch from 7f84c13 to 49072d8 Compare September 5, 2022 10:50
@alexarefev alexarefev marked this pull request as ready for review September 5, 2022 10:53
@koryaga koryaga merged commit 8ed5873 into main Sep 8, 2022
@koryaga koryaga deleted the MANOPD-78395_haproxy_maintenance_check_paas branch September 8, 2022 07:56
ilia1243 added a commit that referenced this pull request Oct 25, 2022
1. Fix #216 is partially reverted (changes in check_paas).
2. VRRP IP with maintenance maintenance-type: "not bind" is now skipped when calculating control_plain.
3. Added new patch which migrates the cluster from not bind VRRP IP.
4. Added ability to deviate enrichment of cluster to simplify patch development.
5. Removed unnecessary template haproxy_mntc.cfg.j2
6. Added more rebust verification of haproxy and VRRP configuration.
7. Other minor fixes and refactoring.
8. Added unit tests for control_plain detection.
koryaga pushed a commit that referenced this pull request Oct 31, 2022
* Skip not bind VRRP IP for control_plain calculation

1. Fix #216 is partially reverted (changes in check_paas).
2. VRRP IP with maintenance maintenance-type: "not bind" is now skipped when calculating control_plain.
3. Added new patch which migrates the cluster from not bind VRRP IP.
4. Added ability to deviate enrichment of cluster to simplify patch development.
5. Removed unnecessary template haproxy_mntc.cfg.j2
6. Added more rebust verification of haproxy and VRRP configuration.
7. Other minor fixes and refactoring.
8. Added unit tests for control_plain detection.

* Skip not bind VRRP IP for control_plain calculation

Added documentation.

* Auto-update license header

* Fix unit test

* Update Installation.md

* Update Installation.md

* Decrease requirements to haproxy in maintenance mode

1. Haproxy in maintenance mode not also listens the node's own internal address, if the balancer is not combined with other roles.
2. Now only one VRRP IP (that is 'not bind') is enough for non-HA schemes.

* Decrease requirements to haproxy in maintenance mode

Added new patch which assigns internal_address for haproxy in maitnenance mode.

* Added unit tests

* Auto-update license header

Co-authored-by: ilia1243 <[email protected]>
Co-authored-by: shmo1218 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
improvement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants