ansible-playbooks icon indicating copy to clipboard operation
ansible-playbooks copied to clipboard

icinga2-ansible-web2-ui is incomplete and requires manual intervention

Open ghost opened this issue 7 years ago • 6 comments

The icinga2-ansible-web2-ui role is does not allow for a fully automated installation and requires manual intervention to finish the installation as indicated by the following message Now generate a token with 'icingacli setup token create' and go at http://IP//icingaweb2/setup to continue the installation

ghost avatar Sep 17 '17 14:09 ghost

The token can be picked up rather easily with a delegation of a shell command:

 - name: Get setup token.
   shell: 'icingacli setup token create | sed "s/.*token is: \(.*\)/\1/g"'
   register: setup_token
   delegate_to: "{{ server }}"

After this, the value can be accessed as: "{{ setup_token.stdout }}"

Skeen avatar Dec 27 '17 17:12 Skeen

@Skeen thanks you for the code contribution , commit 68ff54e is based on your suggestion

aflatto avatar Dec 27 '17 19:12 aflatto

I'm not convinced this issue should be closed yet, there's still the manual step which requires a web browser.

Skeen avatar Dec 28 '17 00:12 Skeen

It might be better to pull the setup_token from the /etc/icingaweb2/setup.token file.

Skeen avatar Dec 28 '17 09:12 Skeen

The steps to automate IcingaWeb2 setup are documented here. It would be nice to have a zero-touch install. However, I don't know how much work is needed to cover all possible setups.

maccadia avatar Mar 15 '18 14:03 maccadia

I've managed to do it for Debian as a proof of concept. My playbook is far from 'viewable' at the moment, but it can be done. I've started to rewrite it based on that playbook. https://github.com/Icinga/ansible-playbooks/pull/101 is the first step.

Bitblade avatar Apr 02 '19 14:04 Bitblade