1920428599
Ansible is scheduled to remove the 'sudo' module and replace it with 'become'. Switch to using this now since it is already supported in 1.9. Closes-Bug: #1504535 Change-Id: Ie63816e36a95c86d54fea5f50325522b41597047
29 lines
1.0 KiB
YAML
29 lines
1.0 KiB
YAML
# Create a default VM
|
|
---
|
|
- hosts: localhost
|
|
connection: local
|
|
name: "Executes install, enrollment, and testing in one playbook"
|
|
become: yes
|
|
gather_facts: yes
|
|
pre_tasks:
|
|
- name: "Set default baremetal.csv file if not already defined"
|
|
set_fact:
|
|
baremetal_csv_file: "/tmp/baremetal.csv"
|
|
when: baremetal_csv_file is not defined
|
|
- name: "Set ci_testing flag if a list of changes are found in the environment variables"
|
|
set_fact:
|
|
ci_testing: true
|
|
when: lookup('env', 'ZUUL_CHANGES') | length > 0
|
|
- name: "Set ci_testing_zuul if it appears we are running in upstream OpenStack CI"
|
|
set_fact:
|
|
ci_testing_zuul: true
|
|
when: "'bare-trusty' in ansible_hostname"
|
|
- name: "Collect process list if running in OpenStack CI"
|
|
command: ps aux
|
|
when: ci_testing_zuul is defined
|
|
- name: "Collect list of listening network sockets if running in OpenStack CI"
|
|
shell: netstat -apn|grep LISTEN
|
|
when: ci_testing_zuul is defined
|
|
roles:
|
|
- role: bifrost-create-vm-nodes
|