@@ -26,7 +26,7 @@ roles, a new role should be submitted in the same PR implementing it.
2626If possible, playbooks should not use tasks directly, only trough a role.
2727
2828Playbooks must use following basic layout. Exposing variables, `edpm_override_hosts `,
29- `edpm_max_fail_percentage ` and `edpm_any_errors_fatal `.
29+ `edpm_max_fail_percentage `, ` edpm_any_errors_fatal `, and `edpm_playbook_environment `.
3030
3131.. code-block :: YAML
3232
@@ -36,9 +36,34 @@ Playbooks must use following basic layout. Exposing variables, `edpm_override_ho
3636 become : true
3737 any_errors_fatal : " {{ edpm_any_errors_fatal | default(true) }}"
3838 max_fail_percentage : " {{ edpm_max_fail_percentage | default(0) }}"
39+ environment : " {{ edpm_playbook_environment | default({}) }}"
3940
4041 This allows for more granular error handling and playbook application by operators.
4142
43+ Environment Variables
44+ ++++++++++++++++++++++
45+
46+ All playbooks must include the `environment ` key at the top level (play level) that
47+ references the `edpm_playbook_environment ` variable. This variable allows operators
48+ to set environment variables (such as proxy settings) that will be applied to all
49+ tasks within the playbook.
50+
51+ The `edpm_playbook_environment ` variable should be a dictionary containing
52+ environment variable key-value pairs. If not defined, it defaults to an empty
53+ dictionary, ensuring backward compatibility.
54+
55+ Example usage:
56+
57+ .. code-block :: YAML
58+
59+ edpm_playbook_environment :
60+ HTTP_PROXY : " http://proxy.example.com:8080"
61+ HTTPS_PROXY : " http://proxy.example.com:8080"
62+ NO_PROXY : " localhost,127.0.0.1"
63+ http_proxy : " http://proxy.example.com:8080"
64+ https_proxy : " http://proxy.example.com:8080"
65+ no_proxy : " localhost,127.0.0.1"
66+
4267 Error handling
4368++++++++++++++
4469
0 commit comments