From 29cda145377142a33971efe6064329b96ab24002 Mon Sep 17 00:00:00 2001 From: Miguel Caballer Date: Tue, 5 Dec 2023 15:49:48 +0100 Subject: [PATCH] Fix test --- molecule/default/molecule.yml | 3 ++- molecule/default/prepare.yml | 10 ++++++++++ 2 files changed, 12 insertions(+), 1 deletion(-) create mode 100644 molecule/default/prepare.yml diff --git a/molecule/default/molecule.yml b/molecule/default/molecule.yml index 28be66e..8a8b467 100644 --- a/molecule/default/molecule.yml +++ b/molecule/default/molecule.yml @@ -5,6 +5,7 @@ scenario: - dependency - destroy - create + - prepare - converge # - idempotence - verify @@ -16,7 +17,7 @@ verifier: name: ansible platforms: - name: instance - image: "geerlingguy/docker-${MOLECULE_DISTRO:-centos8}-ansible:latest" + image: "geerlingguy/docker-${MOLECULE_DISTRO:-ubuntu2004}-ansible:latest" command: ${MOLECULE_DOCKER_COMMAND:-""} volumes: - /sys/fs/cgroup:/sys/fs/cgroup:rw diff --git a/molecule/default/prepare.yml b/molecule/default/prepare.yml new file mode 100644 index 0000000..d96742a --- /dev/null +++ b/molecule/default/prepare.yml @@ -0,0 +1,10 @@ +--- +- name: Prepare + hosts: all + gather_facts: true + + pre_tasks: + - name: Update cache on Debian + apt: + update_cache: yes + when: ansible_os_family == "Debian"