Running a WPScan

To run a scan, update the site.yml file to look like the following code:

- hosts: wordpress  gather_facts: true  become: yes  become_method: sudo  vars_files:    - group_vars/common.yml
  roles:    - roles/stack-install    - roles/stack-config    - roles/wordpress- hosts: scan  gather_facts: true  become: yes  become_method: sudo  vars_files:    - group_vars/common.yml  roles:    - roles/docker    - roles/wpscan

Then run the following command:

$ ansible-playbook -i production site.yml

This should give you the following results (the screenshot shows just the scan rather than the full playbook run, which you should see):

Also, you should find a log file in ...

Get Learn Ansible now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.