-
Notifications
You must be signed in to change notification settings - Fork 696
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Undo some rebase mistakes, address the flakiest test
Restore reverted test-config target in securedrop/Makefile; had lost the change from iteritems->items. Restore molecule/ from develop. Take a sledgehammer to journalist login steps: try logging in up to ten times to get Selenium to see the JS after page load.
- Loading branch information
Showing
6 changed files
with
81 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
--- | ||
|
||
- name: Destroy | ||
hosts: localhost | ||
connection: local | ||
vars: | ||
molecule_file: "{{ lookup('env', 'MOLECULE_FILE') }}" | ||
molecule_instance_config: "{{ lookup('env',' MOLECULE_INSTANCE_CONFIG') }}" | ||
molecule_scenario_dir: "{{ lookup('env','MOLECULE_SCENARIO_DIRECTORY') }}" | ||
molecule_yml: "{{ lookup('file', molecule_file) | molecule_from_yaml }}" | ||
molecule_ephemeral_directory: "{{ lookup('env', 'MOLECULE_EPHEMERAL_DIRECTORY') }}" | ||
tasks: | ||
- name: Destroy molecule instance(s) | ||
molecule_vagrant: | ||
instance_name: "{{ item.name }}" | ||
platform_box: "{{ item.box }}" | ||
provider_name: "{{ molecule_yml.driver.provider.name }}" | ||
force_stop: "{{ item.force_stop | default(True) }}" | ||
|
||
state: destroy | ||
register: server | ||
with_items: "{{ molecule_yml.platforms }}" | ||
|
||
- name: Destroy local molecule ephemeral dir | ||
file: | ||
state: absent | ||
path: "{{ molecule_scenario_dir }}/.molecule" | ||
|
||
# Mandatory configuration for Molecule to function. | ||
|
||
- name: Populate instance config | ||
set_fact: | ||
instance_conf: {} | ||
|
||
- name: Dump instance config | ||
copy: | ||
# NOTE(retr0h): Workaround for Ansible 2.2. | ||
# https://github.com/ansible/ansible/issues/20885 | ||
content: "{{ instance_conf | to_json | from_json | molecule_to_yaml | molecule_header }}" | ||
dest: "{{ molecule_instance_config }}" | ||
when: server.changed | bool |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
--- | ||
- 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 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters