-
Notifications
You must be signed in to change notification settings - Fork 35
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
Bug(?): icinga-director kickstart in fullstack playbook not working #319
Comments
You can also use Flush Handlers
|
Did you try to use flush_handlers in the playbook? Would this be a viable option to use? |
Sorry for the late response. Sure, flushing could "solve" this. |
Results in the following error
I see the api credentials in |
You are already using the flush_handlers but you need to use them after the icinga2 role. As Icinga2 reads its new configuration, in this case the api-users before the reload and after the reload the configuration is active. But I'll discuss this, I'm aware that the icinga2 core should be useable after the role is done. |
I've placed the handler right after the This should be the default director port right?
api-users.conf by ansible
/etc/icingaweb2/modules/director/kickstart.ini
/etc/icingaweb2/modules/director/config.ini
EDIT: running EDIT2: Isn't this crucial step missing as per You can run the CLI command icinga2 api setup to enable the api ? |
I figured it out I guess. The node setup command adds the line Due to But the file is not being used or referenced.
EDIT: Or what is the proper way to handle |
This adds handlers to the 'icingaweb2' role to take care of Icinga Director schema migrations and its kickstart. Running multiple roles in order should also run their handlers in order. This way the Icinga 2 API should be up and operational for the Director to use for kickstart. Fixes #319
This adds handlers to the 'icingaweb2' role to take care of Icinga Director schema migrations and its kickstart. Running multiple roles in order should also run their handlers in order. This way the Icinga 2 API should be up and operational for the Director to use for kickstart. Fixes #319
I've moved two tasks to Does that fix the problem for you @tbauriedel? |
@Donien that should work, thank you! |
The kickstart of the icinga-director cannot be executed in a single fullstack deployment.
The required state of Icinga 2 for the kickstart is created by the restart handler. The handler is executed at the end of all roles.
If you want to install and kickstart the icinga-director in order to have a complete setup, this will fail because the Icinga 2 handler was logically not yet running at this point.
There are workarounds:
run_kickstart: false
and kickstart manuallyicinga.icinga.icingaweb2
only, that is started afterwards.In my opinion a fullstack deployment (including icinga-director kickstart) should work. It could be a idea to flush the handlers after the icinga2 role.
The best-practice from Ansible's point of view with handlers unfortunately collides with the functionality of the icinga components.
The text was updated successfully, but these errors were encountered: