eda_rulebook_activations.yml
In these files we configure the rulebook activations for eda controller.
we will probably do this on a per environment basis, as parameters will vary.
group_vars/all/eda_rulebook_activations.yml
Here we see an example of the configuration for a rulebook activation in EDA.
---
eda_rulebook_activations_all: []
# No config for ALL
...
But you can already see that the variable name used here has the "_all" extension, so the variable will not be overridden as this is not quite a inventory.
Why we do this, will become clear in a moment.
group_vars/dev/eda_rulebook_activations.yml
As we do not configure extra rulebook_activations in development, this file is an empty set.
---
eda_rulebook_activations_dev:
- name: EDA_check_repair_dev_site
description: Check the status of de dev website
organization: ORG_EDA
project: EDA_check_dev_webservice
rulebook: check_website.yml
eda_credentials:
- EDA_controller
decision_environment: EDA_default_de
extra_vars:
check_urls:
- http://web1.dev.lab:80
- http://web2.dev.lab:80
template_to_run: EDA_check_webservers
template_org: ORG_EDA
state: present
...
Here the variable has the "_dev" extension, so the variable will not be overridden.
group_vars/prod/eda_rulebook_activations.yml
As we do not configure extra rulebook_activations in prod, this file is an empty set.
---
eda_rulebook_activations_prod:
- name: EDA_check_repair_prod_site
description: Check the status of de production website
organization: ORG_EDA
project: EDA_check_prod_webservice
rulebook: check_website.yml
eda_credentials:
- EDA_controller
decision_environment: EDA_default_de
extra_vars:
check_urls:
- http://web1.prod.lab:80
- http://web2.prod.lab:80
- http://web3.prod.lab:80
template_to_run: EDA_check_webservers
template_org: ORG_EDA
state: present
...
Here the variable has the "_prod" extension, so the variable will not be overridden.
When we run a pipeline for a certain environment, the inventory structure will provide us with 2 variables:
- eda_rulebook_activations_all
- eda_rulebook_activations_
We will merge these 2 variables into 1: eda_rulebook_activations and feed this to the infra.aap_configuration.eda_rulebook_activations role.