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

Enhancement/icinga2 zones conf #363

Draft
wants to merge 6 commits into
base: main
Choose a base branch
from
Draft

Conversation

Donien
Copy link
Collaborator

@Donien Donien commented Mar 10, 2025

This is currently still work in progress.

This PR will introduce a simple variable (nested dictionary) to define the zone hierarchy.

The corresponding action plugin creates the zones and endpoints for each host according to the variable.
Each host will only know those zones and endpoints it has to know.

Example:

icinga2_zones_conf:
  hierarchy:
    master: # Could be inventory_hostname or Ansible group name
      germany:
        berlin1:
        berlin2:
      france:
        paris:

From this, the plugin will create zones and endpoints based on available variables.
It only returns information. Using the information is still up to the role!


Feedback

There is still a need for a proper way to define variables which will be used for the endpoints host attribute.

2 hosts could have the same parent but in different networks (2 firewall zones for example).
We must be able to provide some kind of mapping to tell a given host the correct address when it wants to access its parent.

  • Master A
  • Satellite B in firewall zone 1
  • Satellite C in firewall zone 2

If B wants to access A, it needs IP-1.
If C wants to access A, it needs IP-2.

This mapping must be defined somewhere.

As a fallback, we can always use inventory_hostname.

@Donien Donien added feature New feature or request help wanted Extra attention is needed labels Mar 10, 2025
@Donien Donien requested a review from mkayontour March 10, 2025 12:58
@Donien Donien self-assigned this Mar 10, 2025
@cla-bot cla-bot bot added the cla/signed label Mar 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla/signed feature New feature or request help wanted Extra attention is needed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant