feat: added molecule tests
Some checks failed
Molecule Tests / molecule-tests (pull_request) Failing after 1m52s

This commit is contained in:
2026-03-11 11:44:59 -03:00
parent c853c75f04
commit 1300e7acc6
7 changed files with 168 additions and 0 deletions

View File

@@ -0,0 +1,37 @@
#SPDX-License-Identifier: GPL-3.0-only
---
- name: Verify
hosts: all
tasks:
- name: Gather service facts
ansible.builtin.service_facts:
- name: Assert postfix service is present
ansible.builtin.assert:
that:
- "'postfix.service' in ansible_facts.services"
- name: Assert dovecot service is present
ansible.builtin.assert:
that:
- "'dovecot.service' in ansible_facts.services"
- name: Check postfix main.cf exists
ansible.builtin.stat:
path: /etc/postfix/main.cf
register: postfix_main_cf
- name: Assert postfix main.cf exists
ansible.builtin.assert:
that:
- postfix_main_cf.stat.exists
- name: Check dovecot.conf exists
ansible.builtin.stat:
path: /etc/dovecot/dovecot.conf
register: dovecot_conf
- name: Assert dovecot.conf exists
ansible.builtin.assert:
that:
- dovecot_conf.stat.exists