Files
@ e970d4afbea4
Branch filter:
Location: majic-ansible-roles/roles/wsgi_website/molecule/default/prepare.yml - annotation
e970d4afbea4
1.2 KiB
text/x-yaml
MAR-128: Upgraded tests for xmpp_server role:
- Switch to new Molecule configuration.
- Updated set-up playbook to use become: yes.
- Moved some preparatory steps outside of the main playbook (eases
idempotence tests).
- Updated tests to reference the yml inventory file.
- Updated tests to use new fixture (host instead of individual ones).
- Switched to extracting hostname instead of hard-coding it in a
couple of tests.
- Renamed hosts to include the Debian version.
- Updated names for some of the test data to cater to change in host
names.
- Switched to using more robust task for populating /etc/hosts.
- Switch to new Molecule configuration.
- Updated set-up playbook to use become: yes.
- Moved some preparatory steps outside of the main playbook (eases
idempotence tests).
- Updated tests to reference the yml inventory file.
- Updated tests to use new fixture (host instead of individual ones).
- Switched to extracting hostname instead of hard-coding it in a
couple of tests.
- Renamed hosts to include the Debian version.
- Updated names for some of the test data to cater to change in host
names.
- Switched to using more robust task for populating /etc/hosts.
a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 a1e0221d24e7 | ---
- name: Prepare
hosts: all
gather_facts: False
tasks:
- name: Install python for Ansible
raw: test -e /usr/bin/python || (apt -y update && apt install -y python-minimal)
become: True
changed_when: False
- hosts: wsgi-website
become: yes
tasks:
- name: Update all caches to avoid errors due to missing remote archives
apt:
update_cache: yes
changed_when: False
- name: Set-up /etc/hosts entries
lineinfile:
dest: /etc/hosts
line: "{{ ansible_eth0.ipv4.address }} parameters-mandatory parameters-optional.local parameters-paste-req wsgi-website"
- name: Install curl for testing redirects and webpage content
apt:
name: curl
state: installed
- name: Install swaks for testing mail forwarding
apt:
name: swaks
state: installed
- name: Install Postfix for testing mail forwarding (Exim4 not covered)
apt:
name: postfix
state: installed
- name: Set-up group for an additional user
group:
name: user
state: present
- name: Set-up additional user for testing mail delivery
user:
name: user
group: user
shell: /bin/bash
|