ansible-collection-hardening/molecule/nginx_hardening/prepare.yml
Sebastian Gumprich 9b50392d8a fix linting
Signed-off-by: Sebastian Gumprich <sebastian.gumprich@t-systems.com>
2022-07-07 16:12:06 +02:00

28 lines
902 B
YAML

---
- name: prepare playbook for kitchen testing "ansible-nginx-hardening" with custom settings
become: true
hosts: all
environment:
http_proxy: "{{ lookup('env', 'http_proxy') | default(omit) }}"
https_proxy: "{{ lookup('env', 'https_proxy') | default(omit) }}"
no_proxy: "{{ lookup('env', 'no_proxy') | default(omit) }}"
tasks:
- name: install required tools on SuSE
community.general.zypper:
name: "python-xml"
state: present
when: ansible_facts.os_family == 'Suse'
- name: install required packages
package:
name: "python3-apt"
update_cache: true
ignore_errors: true # noqa ignore-errors
- name: Set correct distribution Version for Amazon Linux
set_fact:
ansible_distribution_major_version: 7
when: ansible_distribution == 'Amazon'
- include_role:
name: geerlingguy.nginx